docs working
authorThomas Walker Lynch <eknp9n@reasoningtechnology.com>
Tue, 23 Jun 2026 10:53:58 +0000 (10:53 +0000)
committerThomas Walker Lynch <eknp9n@reasoningtechnology.com>
Tue, 23 Jun 2026 10:53:58 +0000 (10:53 +0000)
25 files changed:
administrator/document/RT-Style_locator.js [new file with mode: 0644]
administrator/document/RT-style.js [deleted file]
administrator/document/how-to_release.html
administrator/tool/deploy_internal_locators.py [new file with mode: 0644]
developer/authored/Manuscript.copy/Document/RT-Style_locator.js [new file with mode: 0644]
developer/authored/Manuscript.copy/Document/style_manual.html
developer/authored/Manuscript.copy/Locator/URL-only.js [new file with mode: 0644]
developer/authored/Manuscript.copy/Locator/direct.js [new file with mode: 0644]
developer/authored/Manuscript.copy/Locator/immediate.js [new file with mode: 0644]
developer/authored/Manuscript.copy/Locator/indirect.js [new file with mode: 0644]
developer/document/RT-Style_locator.js [new file with mode: 0644]
developer/document/RT-code-format-Lisp.html
developer/document/RT-code-format.html
developer/document/RT-style.js [deleted file]
developer/document/naming_file-and-directory.html
developer/document/single-file_C-module-and-namespace.html
document/RT-Style_locator.js [new file with mode: 0644]
document/RT-style-HTML.html
document/RT-style.js [deleted file]
document/introduction_Harmony.html
document/role-and-workflow_product-development.html
document/role-and-workflow_product-maintenance.html
shared/document/RT-Style_locator.js [new file with mode: 0644]
shared/document/RT-style.js [deleted file]
temp.sh [new file with mode: 0755]

diff --git a/administrator/document/RT-Style_locator.js b/administrator/document/RT-Style_locator.js
new file mode 100644 (file)
index 0000000..4ded0e8
--- /dev/null
@@ -0,0 +1,37 @@
+/*
+  We have four scenarios
+
+  immediate - used in the RT-style distribution itself (authored, consummer, staged)
+  direct - used in the RT-style project itself, but not in the distribution
+  indirect - the version all Harmony projects use
+  URL_only - always pulls style through a URL, a webserver must be present
+  
+*/
+
+window.RT = window.RT || {};
+
+(function() {
+  const project_name = "RT-Style"; 
+  const path = window.location.pathname;
+  const project_root_index = path.indexOf('/' + project_name + '/');
+  
+  if (project_root_index !== -1) {
+    // substring(0, x) excludes the trailing slash. We must prepend it to the payload.
+    const absolute_project_root = path.substring(0, project_root_index + project_name.length + 1);
+    window.RT.dirpr_library = absolute_project_root + "/consumer/made/Manuscript";
+  } else {
+    // Fallback for when served via local Python HTTP daemon from the project root
+    window.RT.dirpr_library = "../consumer/made/Manuscript";
+  }
+  
+  document.write('<script src="' + window.RT.dirpr_library + '/Core/loader.js"><\/script>');
+  
+  document.write(
+    '<script>' +
+    'window.RT.load("Core/utility");' +
+    'window.RT.load("Core/block_visibility_during_layout");' +
+    'window.RT.load("Theme");' +
+    'window.RT.load("Element/theme_selector");' +
+    '<\/script>'
+  );
+})();
diff --git a/administrator/document/RT-style.js b/administrator/document/RT-style.js
deleted file mode 100644 (file)
index 34cfb22..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-// RT-style.js (Internal RT-style project router)
-window.RT = window.RT || {};
-
-(function() {
-  const project_name = "RT-style"; 
-  const path = window.location.pathname;
-  const project_root_index = path.indexOf('/' + project_name + '/');
-  
-  if (project_root_index !== -1) {
-    // substring(0, x) excludes the trailing slash. We must prepend it to the payload.
-    const absolute_project_root = path.substring(0, project_root_index + project_name.length + 1);
-    window.RT.dirpr_library = absolute_project_root + "/consumer/made/Manuscript";
-  } else {
-    // Fallback for when served via local Python HTTP daemon from the project root
-    window.RT.dirpr_library = "../consumer/made/Manuscript";
-  }
-  
-  document.write('<script src="' + window.RT.dirpr_library + '/Core/loader.js"><\/script>');
-  
-  document.write(
-    '<script>' +
-    'window.RT.load("Core/utility");' +
-    'window.RT.load("Core/block_visibility_during_layout");' +
-    'window.RT.load("Theme");' +
-    'window.RT.load("Element/theme_selector");' +
-    '<\/script>'
-  );
-})();
index 3c70557..80da3cc 100644 (file)
@@ -3,7 +3,7 @@
   <head>
     <meta charset="UTF-8">
     <title>Release howto</title>
-    <script src="RT-style.js"></script>
+    <script src="RT-Style_locator.js"></script>
     <script>
       window.RT.load('Layout/article_tech_ref');
     </script>
diff --git a/administrator/tool/deploy_internal_locators.py b/administrator/tool/deploy_internal_locators.py
new file mode 100644 (file)
index 0000000..90311a7
--- /dev/null
@@ -0,0 +1,50 @@
+#!/usr/bin/env python3
+import sys
+import os
+import stat
+import shutil
+from pathlib import Path
+
+def deploy_internal_locators(locator_dir_path):
+    locator_dir = Path(locator_dir_path)
+    if not locator_dir.is_dir():
+        print(f"Error: Locator directory not found at {locator_dir_path}")
+        sys.exit(1)
+
+    immediate_js = locator_dir / "immediate.js"
+    direct_js = locator_dir / "direct.js"
+
+    if not immediate_js.exists() or not direct_js.exists():
+        print("Error: Source locator files missing in the specified directory.")
+        sys.exit(1)
+
+    repo_home = Path(os.environ.get("REPO_HOME", "."))
+    IGNORED_DIRS = {".git", "scratchpad", "consumer"}
+
+    for root, dirs, files in os.walk(repo_home):
+        # Prune ignored directories in place to prevent descending into them
+        dirs[:] = [d for d in dirs if d not in IGNORED_DIRS]
+        
+        current_path = Path(root)
+        if current_path.name.lower() == "document":
+            target_file = current_path / "RT-Style_locator.js"
+            
+            # Evaluate the path to determine the correct structural locator
+            if "developer/authored/Manuscript" in current_path.as_posix():
+                source_file = immediate_js
+            else:
+                source_file = direct_js
+
+            # Eliminate permission denial on read-only consumer artifacts
+            if target_file.exists():
+                target_file.chmod(target_file.stat().st_mode | stat.S_IWUSR)
+            
+            shutil.copyfile(source_file, target_file)
+            print(f"Copied {source_file.name} -> {target_file}")
+
+if __name__ == "__main__":
+    if len(sys.argv) != 2:
+        print("Usage: python3 deploy_internal_locators.py <path_to_Locator_directory>")
+        sys.exit(1)
+    
+    deploy_internal_locators(sys.argv[1])
diff --git a/developer/authored/Manuscript.copy/Document/RT-Style_locator.js b/developer/authored/Manuscript.copy/Document/RT-Style_locator.js
new file mode 100644 (file)
index 0000000..07d9fb6
--- /dev/null
@@ -0,0 +1,29 @@
+/*
+  We have four scenarios
+
+  immediate - used in the RT-style distribution itself (authored, consummer, staged)
+  direct - used in the RT-style project itself, but not in the distribution
+  indirect - the version all Harmony projects use
+  URL_only - always pulls style through a URL, a webserver must be present
+
+*/
+
+window.RT = window.RT || {};
+
+(function() {
+  // We are the style library, so ...
+  window.RT.dirpr_library = "..";
+  
+  // 1. Inject the loader script
+  document.write('<script src="' + window.RT.dirpr_library + '/Core/loader.js"><\/script>');
+  
+  // 2. Inject a secondary script block for the core dependencies
+  document.write(
+    '<script>' +
+    'window.RT.load("Core/utility");' +
+    'window.RT.load("Core/block_visibility_during_layout");' +
+    'window.RT.load("Theme");' +
+    'window.RT.load("Element/theme_selector");' +
+    '<\/script>'
+  );
+})();
index dba65a2..deffcfe 100644 (file)
@@ -4,7 +4,7 @@
     <meta charset="UTF-8">
     <title>Your Document Title</title>
     
-    <script src="RT-style.js"></script>
+    <script src="RT-Style_locator.js"></script>
     <script>
       window.RT.load('Layout/article_tech_ref');
     </script>
diff --git a/developer/authored/Manuscript.copy/Locator/URL-only.js b/developer/authored/Manuscript.copy/Locator/URL-only.js
new file mode 100644 (file)
index 0000000..66e47d7
--- /dev/null
@@ -0,0 +1,16 @@
+// RT-style_url_only.js
+window.RT = window.RT || {};
+
+(function() {
+  window.RT.dirpr_library = "https://style.ReasoningTechnology.com/Manuscript"; // Production URL
+  
+  document.write('<script src="' + window.RT.dirpr_library + '/Core/loader.js"><\/script>');
+  document.write(
+    '<script>' +
+    'window.RT.load("Core/utility");' +
+    'window.RT.load("Core/block_visibility_during_layout");' +
+    'window.RT.load("Theme");' +
+    'window.RT.load("Element/theme_selector");' +
+    '<\/script>'
+  );
+})();
diff --git a/developer/authored/Manuscript.copy/Locator/direct.js b/developer/authored/Manuscript.copy/Locator/direct.js
new file mode 100644 (file)
index 0000000..4ded0e8
--- /dev/null
@@ -0,0 +1,37 @@
+/*
+  We have four scenarios
+
+  immediate - used in the RT-style distribution itself (authored, consummer, staged)
+  direct - used in the RT-style project itself, but not in the distribution
+  indirect - the version all Harmony projects use
+  URL_only - always pulls style through a URL, a webserver must be present
+  
+*/
+
+window.RT = window.RT || {};
+
+(function() {
+  const project_name = "RT-Style"; 
+  const path = window.location.pathname;
+  const project_root_index = path.indexOf('/' + project_name + '/');
+  
+  if (project_root_index !== -1) {
+    // substring(0, x) excludes the trailing slash. We must prepend it to the payload.
+    const absolute_project_root = path.substring(0, project_root_index + project_name.length + 1);
+    window.RT.dirpr_library = absolute_project_root + "/consumer/made/Manuscript";
+  } else {
+    // Fallback for when served via local Python HTTP daemon from the project root
+    window.RT.dirpr_library = "../consumer/made/Manuscript";
+  }
+  
+  document.write('<script src="' + window.RT.dirpr_library + '/Core/loader.js"><\/script>');
+  
+  document.write(
+    '<script>' +
+    'window.RT.load("Core/utility");' +
+    'window.RT.load("Core/block_visibility_during_layout");' +
+    'window.RT.load("Theme");' +
+    'window.RT.load("Element/theme_selector");' +
+    '<\/script>'
+  );
+})();
diff --git a/developer/authored/Manuscript.copy/Locator/immediate.js b/developer/authored/Manuscript.copy/Locator/immediate.js
new file mode 100644 (file)
index 0000000..07d9fb6
--- /dev/null
@@ -0,0 +1,29 @@
+/*
+  We have four scenarios
+
+  immediate - used in the RT-style distribution itself (authored, consummer, staged)
+  direct - used in the RT-style project itself, but not in the distribution
+  indirect - the version all Harmony projects use
+  URL_only - always pulls style through a URL, a webserver must be present
+
+*/
+
+window.RT = window.RT || {};
+
+(function() {
+  // We are the style library, so ...
+  window.RT.dirpr_library = "..";
+  
+  // 1. Inject the loader script
+  document.write('<script src="' + window.RT.dirpr_library + '/Core/loader.js"><\/script>');
+  
+  // 2. Inject a secondary script block for the core dependencies
+  document.write(
+    '<script>' +
+    'window.RT.load("Core/utility");' +
+    'window.RT.load("Core/block_visibility_during_layout");' +
+    'window.RT.load("Theme");' +
+    'window.RT.load("Element/theme_selector");' +
+    '<\/script>'
+  );
+})();
diff --git a/developer/authored/Manuscript.copy/Locator/indirect.js b/developer/authored/Manuscript.copy/Locator/indirect.js
new file mode 100644 (file)
index 0000000..f338031
--- /dev/null
@@ -0,0 +1,54 @@
+/*
+  We have four scenarios
+
+  immediate - used in the RT-Style distribution itself (authored, consummer, staged)
+  direct - used in the RT-Style project itself, but not in the distribution
+  indirect - the version all Harmony projects use
+  URL_only - always pulls style through a URL, a webserver must be present
+  
+*/
+
+window.RT = window.RT || {};
+
+// --- Configuration ---
+// Define the consumer project name to allow dynamic local file:// calculation.
+window.RT.project_name = "Harmony"; 
+
+// Fallback URL when served over a network where the project root is not in the URI.
+window.RT.server_url = "http://localhost:8000/shared/linked-project/RT-Style/made/Manuscript";
+
+(function() {
+  let style_path = window.RT.server_url;
+
+  if (window.RT.project_name) {
+    const path = window.location.pathname;
+    const project_root_index = path.indexOf('/' + window.RT.project_name + '/');
+    
+    if (project_root_index !== -1) {
+      // substring(0, stop) extracts up to the project name, leaving off the trailing slash.
+      // We append the explicit forward slash before navigating into the shared boundary.
+      const absolute_project_root = path.substring(0, project_root_index + window.RT.project_name.length + 1);
+      
+      // The symlink 'RT-Style' already drops us inside the 'consumer/' directory, 
+      // so we proceed directly to 'made/Manuscript'.
+      style_path = absolute_project_root + "/shared/linked-project/RT-Style/made/Manuscript";
+    } else {
+      console.warn("RT-Style: Cannot locate project root '/" + window.RT.project_name + "/' in URI. Falling back to server_url.");
+    }
+  }
+  
+  window.RT.dirpr_library = style_path;
+  
+  // 1. Inject the loader script
+  document.write('<script src="' + window.RT.dirpr_library + '/Core/loader.js"><\/script>');
+  
+  // 2. Inject the secondary script block for core dependencies
+  document.write(
+    '<script>' +
+    'window.RT.load("Core/utility");' +
+    'window.RT.load("Core/block_visibility_during_layout");' +
+    'window.RT.load("Theme");' +
+    'window.RT.load("Element/theme_selector");' +
+    '<\/script>'
+  );
+})();
diff --git a/developer/document/RT-Style_locator.js b/developer/document/RT-Style_locator.js
new file mode 100644 (file)
index 0000000..4ded0e8
--- /dev/null
@@ -0,0 +1,37 @@
+/*
+  We have four scenarios
+
+  immediate - used in the RT-style distribution itself (authored, consummer, staged)
+  direct - used in the RT-style project itself, but not in the distribution
+  indirect - the version all Harmony projects use
+  URL_only - always pulls style through a URL, a webserver must be present
+  
+*/
+
+window.RT = window.RT || {};
+
+(function() {
+  const project_name = "RT-Style"; 
+  const path = window.location.pathname;
+  const project_root_index = path.indexOf('/' + project_name + '/');
+  
+  if (project_root_index !== -1) {
+    // substring(0, x) excludes the trailing slash. We must prepend it to the payload.
+    const absolute_project_root = path.substring(0, project_root_index + project_name.length + 1);
+    window.RT.dirpr_library = absolute_project_root + "/consumer/made/Manuscript";
+  } else {
+    // Fallback for when served via local Python HTTP daemon from the project root
+    window.RT.dirpr_library = "../consumer/made/Manuscript";
+  }
+  
+  document.write('<script src="' + window.RT.dirpr_library + '/Core/loader.js"><\/script>');
+  
+  document.write(
+    '<script>' +
+    'window.RT.load("Core/utility");' +
+    'window.RT.load("Core/block_visibility_during_layout");' +
+    'window.RT.load("Theme");' +
+    'window.RT.load("Element/theme_selector");' +
+    '<\/script>'
+  );
+})();
index 61730d3..4c104ac 100644 (file)
@@ -3,7 +3,7 @@
   <head>
     <meta charset="UTF-8">
     <title>RT Code Format: Lisp Addendum</title>
-    <script src="RT-style.js"></script>
+    <script src="RT-Style_locator.js"></script>
     <script>
       window.RT.load('Layout/article_tech_ref');
     </script>
index a162364..55eecb2 100644 (file)
@@ -3,7 +3,7 @@
   <head>
     <meta charset="UTF-8">
     <title>RT code format conventions</title>
-    <script src="RT-style.js"></script>
+    <script src="RT-Style_locator.js"></script>
     <script>
       window.RT.load('Layout/article_tech_ref');
     </script>
diff --git a/developer/document/RT-style.js b/developer/document/RT-style.js
deleted file mode 100644 (file)
index 34cfb22..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-// RT-style.js (Internal RT-style project router)
-window.RT = window.RT || {};
-
-(function() {
-  const project_name = "RT-style"; 
-  const path = window.location.pathname;
-  const project_root_index = path.indexOf('/' + project_name + '/');
-  
-  if (project_root_index !== -1) {
-    // substring(0, x) excludes the trailing slash. We must prepend it to the payload.
-    const absolute_project_root = path.substring(0, project_root_index + project_name.length + 1);
-    window.RT.dirpr_library = absolute_project_root + "/consumer/made/Manuscript";
-  } else {
-    // Fallback for when served via local Python HTTP daemon from the project root
-    window.RT.dirpr_library = "../consumer/made/Manuscript";
-  }
-  
-  document.write('<script src="' + window.RT.dirpr_library + '/Core/loader.js"><\/script>');
-  
-  document.write(
-    '<script>' +
-    'window.RT.load("Core/utility");' +
-    'window.RT.load("Core/block_visibility_during_layout");' +
-    'window.RT.load("Theme");' +
-    'window.RT.load("Element/theme_selector");' +
-    '<\/script>'
-  );
-})();
index a8fad1e..07e8d67 100644 (file)
@@ -3,7 +3,7 @@
   <head>
     <meta charset="UTF-8">
     <title>File and directory naming conventions</title>
-    <script src="RT-style.js"></script>
+    <script src="RT-Style_locator.js"></script>
     <script>
       window.RT.load('Layout/article_tech_ref');
     </script>
index db0e657..61acebe 100644 (file)
@@ -3,7 +3,7 @@
   <head>
     <meta charset="UTF-8">
     <title>C modules, namespaces, and the build lifecycle</title>
-    <script src="RT-style.js"></script>
+    <script src="RT-Style_locator.js"></script>
     <script>
       window.RT.load('Layout/article_tech_ref');
     </script>
diff --git a/document/RT-Style_locator.js b/document/RT-Style_locator.js
new file mode 100644 (file)
index 0000000..4ded0e8
--- /dev/null
@@ -0,0 +1,37 @@
+/*
+  We have four scenarios
+
+  immediate - used in the RT-style distribution itself (authored, consummer, staged)
+  direct - used in the RT-style project itself, but not in the distribution
+  indirect - the version all Harmony projects use
+  URL_only - always pulls style through a URL, a webserver must be present
+  
+*/
+
+window.RT = window.RT || {};
+
+(function() {
+  const project_name = "RT-Style"; 
+  const path = window.location.pathname;
+  const project_root_index = path.indexOf('/' + project_name + '/');
+  
+  if (project_root_index !== -1) {
+    // substring(0, x) excludes the trailing slash. We must prepend it to the payload.
+    const absolute_project_root = path.substring(0, project_root_index + project_name.length + 1);
+    window.RT.dirpr_library = absolute_project_root + "/consumer/made/Manuscript";
+  } else {
+    // Fallback for when served via local Python HTTP daemon from the project root
+    window.RT.dirpr_library = "../consumer/made/Manuscript";
+  }
+  
+  document.write('<script src="' + window.RT.dirpr_library + '/Core/loader.js"><\/script>');
+  
+  document.write(
+    '<script>' +
+    'window.RT.load("Core/utility");' +
+    'window.RT.load("Core/block_visibility_during_layout");' +
+    'window.RT.load("Theme");' +
+    'window.RT.load("Element/theme_selector");' +
+    '<\/script>'
+  );
+})();
index 1ed8fed..8bbf7e8 100644 (file)
@@ -3,7 +3,7 @@
   <head>
     <meta charset="UTF-8">
     <title>RT semantic HTML tags</title>
-    <script src="RT-style.js"></script>
+    <script src="RT-Style_locator.js"></script>
     <script>
       window.RT.load('Layout/article_tech_ref');
     </script>
diff --git a/document/RT-style.js b/document/RT-style.js
deleted file mode 100644 (file)
index 34cfb22..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-// RT-style.js (Internal RT-style project router)
-window.RT = window.RT || {};
-
-(function() {
-  const project_name = "RT-style"; 
-  const path = window.location.pathname;
-  const project_root_index = path.indexOf('/' + project_name + '/');
-  
-  if (project_root_index !== -1) {
-    // substring(0, x) excludes the trailing slash. We must prepend it to the payload.
-    const absolute_project_root = path.substring(0, project_root_index + project_name.length + 1);
-    window.RT.dirpr_library = absolute_project_root + "/consumer/made/Manuscript";
-  } else {
-    // Fallback for when served via local Python HTTP daemon from the project root
-    window.RT.dirpr_library = "../consumer/made/Manuscript";
-  }
-  
-  document.write('<script src="' + window.RT.dirpr_library + '/Core/loader.js"><\/script>');
-  
-  document.write(
-    '<script>' +
-    'window.RT.load("Core/utility");' +
-    'window.RT.load("Core/block_visibility_during_layout");' +
-    'window.RT.load("Theme");' +
-    'window.RT.load("Element/theme_selector");' +
-    '<\/script>'
-  );
-})();
index 40a73dd..db3fca3 100644 (file)
@@ -3,7 +3,7 @@
   <head>
     <meta charset="UTF-8">
     <title>Introduction to Harmony</title>
-    <script src="RT-style.js"></script>
+    <script src="RT-Style_locator.js"></script>
     <script>
       window.RT.load('Layout/article_tech_ref');
     </script>
index 47c5b2a..2a4f655 100644 (file)
@@ -3,7 +3,7 @@
   <head>
     <meta charset="UTF-8">
     <title>Product development roles and workflow</title>
-    <script src="RT-style.js"></script>
+    <script src="RT-Style_locator.js"></script>
     <script>
       window.RT.load('Layout/article_tech_ref');
     </script>
index e2c59db..1f76dd0 100644 (file)
@@ -3,7 +3,7 @@
   <head>
     <meta charset="UTF-8">
     <title>Product maintenance roles and workflow</title>
-    <script src="RT-style.js"></script>
+    <script src="RT-Style_locator.js"></script>
     <script>
       window.RT.load('Layout/article_tech_ref');
     </script>
diff --git a/shared/document/RT-Style_locator.js b/shared/document/RT-Style_locator.js
new file mode 100644 (file)
index 0000000..4ded0e8
--- /dev/null
@@ -0,0 +1,37 @@
+/*
+  We have four scenarios
+
+  immediate - used in the RT-style distribution itself (authored, consummer, staged)
+  direct - used in the RT-style project itself, but not in the distribution
+  indirect - the version all Harmony projects use
+  URL_only - always pulls style through a URL, a webserver must be present
+  
+*/
+
+window.RT = window.RT || {};
+
+(function() {
+  const project_name = "RT-Style"; 
+  const path = window.location.pathname;
+  const project_root_index = path.indexOf('/' + project_name + '/');
+  
+  if (project_root_index !== -1) {
+    // substring(0, x) excludes the trailing slash. We must prepend it to the payload.
+    const absolute_project_root = path.substring(0, project_root_index + project_name.length + 1);
+    window.RT.dirpr_library = absolute_project_root + "/consumer/made/Manuscript";
+  } else {
+    // Fallback for when served via local Python HTTP daemon from the project root
+    window.RT.dirpr_library = "../consumer/made/Manuscript";
+  }
+  
+  document.write('<script src="' + window.RT.dirpr_library + '/Core/loader.js"><\/script>');
+  
+  document.write(
+    '<script>' +
+    'window.RT.load("Core/utility");' +
+    'window.RT.load("Core/block_visibility_during_layout");' +
+    'window.RT.load("Theme");' +
+    'window.RT.load("Element/theme_selector");' +
+    '<\/script>'
+  );
+})();
diff --git a/shared/document/RT-style.js b/shared/document/RT-style.js
deleted file mode 100644 (file)
index 34cfb22..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-// RT-style.js (Internal RT-style project router)
-window.RT = window.RT || {};
-
-(function() {
-  const project_name = "RT-style"; 
-  const path = window.location.pathname;
-  const project_root_index = path.indexOf('/' + project_name + '/');
-  
-  if (project_root_index !== -1) {
-    // substring(0, x) excludes the trailing slash. We must prepend it to the payload.
-    const absolute_project_root = path.substring(0, project_root_index + project_name.length + 1);
-    window.RT.dirpr_library = absolute_project_root + "/consumer/made/Manuscript";
-  } else {
-    // Fallback for when served via local Python HTTP daemon from the project root
-    window.RT.dirpr_library = "../consumer/made/Manuscript";
-  }
-  
-  document.write('<script src="' + window.RT.dirpr_library + '/Core/loader.js"><\/script>');
-  
-  document.write(
-    '<script>' +
-    'window.RT.load("Core/utility");' +
-    'window.RT.load("Core/block_visibility_during_layout");' +
-    'window.RT.load("Theme");' +
-    'window.RT.load("Element/theme_selector");' +
-    '<\/script>'
-  );
-})();
diff --git a/temp.sh b/temp.sh
new file mode 100755 (executable)
index 0000000..ee9bc84
--- /dev/null
+++ b/temp.sh
@@ -0,0 +1,29 @@
+#!/usr/bin/env bash
+# deploy_internal_locators.sh
+
+LOCATOR_DIR="$1"
+
+if [[ -z "$LOCATOR_DIR" || ! -d "$LOCATOR_DIR" ]]; then
+    echo "Error: Must provide a valid path to the Locator directory."
+    echo "Usage: $0 <path_to_Locator_directory>"
+    exit 1
+fi
+
+# Default to current directory if REPO_HOME is not set
+TARGET_BASE="${REPO_HOME:-.}"
+
+# Walk the tree, pruning .git, scratchpad, and consumer
+find "$TARGET_BASE" -type d \( -name ".git" -o -name "scratchpad" -o -name "consumer" \) -prune -o -type d -iname "document" -print | while IFS= read -r doc_dir; do
+    
+    # Evaluate the path to determine the correct structural locator
+    if [[ "$doc_dir" == *"developer/authored/Manuscript"* ]]; then
+        cp "$LOCATOR_DIR/immediate.js" "$doc_dir/RT-Style_locator.js"
+        echo "Copied immediate.js -> $doc_dir/RT-Style_locator.js"
+    else
+        cp "$LOCATOR_DIR/direct.js" "$doc_dir/RT-Style_locator.js"
+        echo "Copied direct.js    -> $doc_dir/RT-Style_locator.js"
+    fi
+    
+done
+
+echo "Internal locator deployment complete."