@technomoron/agent-run 0.99.22 → 0.99.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3,3 +3,20 @@
3
3
 
4
4
  # Optional generated caches
5
5
  **/.agent-run-cache/
6
+
7
+ # Legacy Codex runtime state
8
+ **/auth.json
9
+ **/history.jsonl
10
+ **/sessions/
11
+ **/archived_sessions/
12
+ **/log/
13
+ **/logs/
14
+ **/shell_snapshots/
15
+ **/*.sqlite*
16
+ **/models_cache.json
17
+ **/cache/
18
+ **/.tmp/
19
+ **/installation_id
20
+ **/version.json
21
+ **/.personality_migration
22
+ **/skills/.system/
@@ -7,6 +7,9 @@ description: Use before package releases in {{ profile }}.
7
7
 
8
8
  Use this checklist instead of an external `repo-check` command.
9
9
 
10
+ Require every GitHub Actions `uses:` reference to use a full commit SHA. The
11
+ `actions/setup-node` pin must be v6-compatible and use `node-version: 24`.
12
+
10
13
  Run configured checks after package metadata, release notes, workflow, lockfile, and git-state review:
11
14
 
12
15
  {% for check in checks %}
@@ -1,24 +1,22 @@
1
1
  {% if permissionsAllow.length %}{
2
2
  "env": {
3
- "AGENT_DIR": "{{ agentDir }}",
4
- "AGENT_PROFILE_DIR": "{{ profileDir }}",
5
- "AGENT_RUN_PROJECT_ROOT": "{{ projectRoot }}",
6
- "AGENT_GLOBAL_MEMORY_DIR": "{{ paths.globalMemoryDir }}",
7
- "STARTER_PROFILE": "{{ profile }}"
3
+ "AGENT_DIR": {{ agentDir | dump }},
4
+ "AGENT_PROFILE_DIR": {{ profileDir | dump }},
5
+ "AGENT_RUN_PROJECT_ROOT": {{ projectRoot | dump }},
6
+ "AGENT_GLOBAL_MEMORY_DIR": {{ paths.globalMemoryDir | dump }},
7
+ "STARTER_PROFILE": {{ profile | dump }}
8
8
  },
9
9
  "permissions": {
10
- "allow": [
11
- "{{ permissionsAllow | join('",\n "') }}"
12
- ]
10
+ "allow": {{ permissionsAllow | dump }}
13
11
  }
14
12
  }
15
13
  {% else %}{
16
14
  "env": {
17
- "AGENT_DIR": "{{ agentDir }}",
18
- "AGENT_PROFILE_DIR": "{{ profileDir }}",
19
- "AGENT_RUN_PROJECT_ROOT": "{{ projectRoot }}",
20
- "AGENT_GLOBAL_MEMORY_DIR": "{{ paths.globalMemoryDir }}",
21
- "STARTER_PROFILE": "{{ profile }}"
15
+ "AGENT_DIR": {{ agentDir | dump }},
16
+ "AGENT_PROFILE_DIR": {{ profileDir | dump }},
17
+ "AGENT_RUN_PROJECT_ROOT": {{ projectRoot | dump }},
18
+ "AGENT_GLOBAL_MEMORY_DIR": {{ paths.globalMemoryDir | dump }},
19
+ "STARTER_PROFILE": {{ profile | dump }}
22
20
  }
23
21
  }
24
22
  {% endif %}
@@ -1,13 +1,12 @@
1
1
  # Starter global Codex config
2
2
  project_doc_max_bytes = 32768
3
- sandbox_mode = "danger-full-access"
3
+ approval_policy = "on-request"
4
+ sandbox_mode = "workspace-write"
4
5
 
5
6
  [sandbox_workspace_write]
6
7
  writable_roots = [
7
- "{{ projectRoot }}",
8
- "{{ agentDir }}",
9
- "{{ profileDir }}",
10
- "{{ paths.memoriesDir }}",
11
- "{{ paths.globalMemoryDir }}"
8
+ {{ projectRoot | dump }},
9
+ {{ paths.reviewDir | dump }},
10
+ {{ paths.memoriesDir | dump }}
12
11
  ]
13
12
  network_access = false
@@ -1,25 +1,23 @@
1
1
  {% if permissionsAllow.length %}{
2
2
  "env": {
3
- "AGENT_DIR": "{{ agentDir }}",
4
- "AGENT_PROFILE_DIR": "{{ profileDir }}",
5
- "AGENT_RUN_PROJECT_ROOT": "{{ projectRoot }}",
6
- "AGENT_GLOBAL_MEMORY_DIR": "{{ paths.globalMemoryDir }}",
7
- "STARTER_PROFILE": "{{ profile }}",
3
+ "AGENT_DIR": {{ agentDir | dump }},
4
+ "AGENT_PROFILE_DIR": {{ profileDir | dump }},
5
+ "AGENT_RUN_PROJECT_ROOT": {{ projectRoot | dump }},
6
+ "AGENT_GLOBAL_MEMORY_DIR": {{ paths.globalMemoryDir | dump }},
7
+ "STARTER_PROFILE": {{ profile | dump }},
8
8
  "STARTER_OVERRIDE": "true"
9
9
  },
10
10
  "permissions": {
11
- "allow": [
12
- "{{ permissionsAllow | join('",\n "') }}"
13
- ]
11
+ "allow": {{ permissionsAllow | dump }}
14
12
  }
15
13
  }
16
14
  {% else %}{
17
15
  "env": {
18
- "AGENT_DIR": "{{ agentDir }}",
19
- "AGENT_PROFILE_DIR": "{{ profileDir }}",
20
- "AGENT_RUN_PROJECT_ROOT": "{{ projectRoot }}",
21
- "AGENT_GLOBAL_MEMORY_DIR": "{{ paths.globalMemoryDir }}",
22
- "STARTER_PROFILE": "{{ profile }}",
16
+ "AGENT_DIR": {{ agentDir | dump }},
17
+ "AGENT_PROFILE_DIR": {{ profileDir | dump }},
18
+ "AGENT_RUN_PROJECT_ROOT": {{ projectRoot | dump }},
19
+ "AGENT_GLOBAL_MEMORY_DIR": {{ paths.globalMemoryDir | dump }},
20
+ "STARTER_PROFILE": {{ profile | dump }},
23
21
  "STARTER_OVERRIDE": "true"
24
22
  }
25
23
  }
@@ -1,13 +1,12 @@
1
1
  # Starter profile Codex override
2
2
  project_doc_max_bytes = 65536
3
- sandbox_mode = "danger-full-access"
3
+ approval_policy = "on-request"
4
+ sandbox_mode = "workspace-write"
4
5
 
5
6
  [sandbox_workspace_write]
6
7
  writable_roots = [
7
- "{{ projectRoot }}",
8
- "{{ agentDir }}",
9
- "{{ profileDir }}",
10
- "{{ paths.memoriesDir }}",
11
- "{{ paths.globalMemoryDir }}"
8
+ {{ projectRoot | dump }},
9
+ {{ paths.reviewDir | dump }},
10
+ {{ paths.memoriesDir | dump }}
12
11
  ]
13
12
  network_access = false
@@ -1,11 +1,16 @@
1
1
  [Unit]
2
- Description=Update global AI and developer CLI packages
2
+ Description=Update global AI CLI and package-manager tools
3
3
  After=network-online.target
4
4
  Wants=network-online.target
5
5
 
6
6
  [Service]
7
7
  Type=oneshot
8
+ KillMode=process
9
+ UMask=0022
10
+ TimeoutStartSec=30min
8
11
  Environment=HOME=/root
9
- Environment=NPM_CONFIG_PREFIX=/usr
10
- Environment=PNPM_HOME=/usr/local/bin
12
+ Environment=XDG_CONFIG_HOME=/root/.config
13
+ Environment=NPM_CONFIG_PREFIX=/usr/local
14
+ Environment=PNPM_HOME=/usr/local
15
+ Environment=PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
11
16
  ExecStart=/usr/local/lib/agent-run/update-ai-tools.sh
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@technomoron/agent-run",
3
- "version": "0.99.22",
3
+ "version": "0.99.24",
4
4
  "packageManager": "pnpm@10.28.1",
5
5
  "bin": {
6
6
  "agent-run": "dist/agent-run.js"
@@ -26,8 +26,9 @@
26
26
  "clean:dist": "rimraf ./dist/",
27
27
  "cleanbuild": "run-s clean:dist build",
28
28
  "prepack": "run-s build",
29
- "test": "run-s build test:integration",
29
+ "test": "run-s build test:integration test:release",
30
30
  "test:integration": "bash ./scripts/test.sh",
31
+ "test:release": "bash ./scripts/test-release.sh",
31
32
  "release": "bash ./scripts/release.sh",
32
33
  "release:check": "bash ./scripts/release-check.sh",
33
34
  "release:preflight": "pnpm cleanbuild && pnpm test && pnpm release:check -- --local",
@@ -41,14 +42,16 @@
41
42
  },
42
43
  "homepage": "https://github.com/technomoron/agent-run#readme",
43
44
  "devDependencies": {
44
- "@types/nunjucks": "^3.2.6",
45
+ "@types/cross-spawn": "^6.0.6",
45
46
  "@types/node": "^20.19.11",
47
+ "@types/nunjucks": "^3.2.6",
46
48
  "npm-run-all": "^4.1.5",
47
- "pnpm": "^10.28.1",
49
+ "pnpm": "10.28.1",
48
50
  "rimraf": "^6.1.3",
49
51
  "typescript": "^5.9.3"
50
52
  },
51
53
  "dependencies": {
54
+ "cross-spawn": "^7.0.6",
52
55
  "jsonc-parser": "^3.3.1",
53
56
  "nunjucks": "^3.2.4"
54
57
  }
@@ -24,7 +24,6 @@ SYSTEMD_DIR="${SYSTEMD_DIR:-/etc/systemd/system}"
24
24
  ORIGINAL_ARGS=("$@")
25
25
 
26
26
  INSTALL_AI_TOOLS=0
27
- INSTALL_ALL=0
28
27
  DRY_RUN=0
29
28
 
30
29
  while [ "$#" -gt 0 ]; do
@@ -34,7 +33,6 @@ while [ "$#" -gt 0 ]; do
34
33
  shift
35
34
  ;;
36
35
  --all)
37
- INSTALL_ALL=1
38
36
  INSTALL_AI_TOOLS=1
39
37
  shift
40
38
  ;;
@@ -2,22 +2,40 @@
2
2
  set -euo pipefail
3
3
 
4
4
  export HOME="${HOME:-/root}"
5
- export NPM_CONFIG_PREFIX="${NPM_CONFIG_PREFIX:-/usr}"
6
- export PNPM_HOME="${PNPM_HOME:-/usr/local/bin}"
5
+ export NPM_CONFIG_PREFIX="${NPM_CONFIG_PREFIX:-/usr/local}"
6
+ export PNPM_HOME="${PNPM_HOME:-/usr/local}"
7
7
  export PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:${PATH:-}"
8
8
 
9
- NPM_BIN="${AI_TOOLS_NPM_BIN:-/usr/bin/npm}"
9
+ NPM_BIN="${AI_TOOLS_NPM_BIN:-/usr/local/bin/npm}"
10
10
  APT_GET_BIN="${AI_TOOLS_APT_GET_BIN:-/usr/bin/apt-get}"
11
11
 
12
- AI_TOOLS_NPM_PACKAGES="${AI_TOOLS_NPM_PACKAGES:-npm pnpm netlify-cli@latest @openai/codex@latest @anthropic-ai/claude-code@latest @technomoron/agent-run@latest @technomoron/repo-check@latest}"
12
+ AI_TOOLS_NPM_PACKAGES="${AI_TOOLS_NPM_PACKAGES:-npm@latest pnpm@latest corepack@latest fallow@latest ripgrep@latest pm2@latest tsx@latest typescript@latest @openai/codex@latest @anthropic-ai/claude-code@latest @technomoron/agent-run@latest}"
13
+ AI_TOOLS_PNPM_PACKAGE="${AI_TOOLS_PNPM_PACKAGE:-pnpm@latest}"
13
14
  AI_TOOLS_APT_PACKAGES="${AI_TOOLS_APT_PACKAGES:-gh}"
14
15
 
16
+ if [ "$(id -u)" -ne 0 ]; then
17
+ echo "update-ai-tools.sh must run as root" >&2
18
+ exit 1
19
+ fi
20
+
15
21
  if [ -n "$AI_TOOLS_NPM_PACKAGES" ]; then
16
- # shellcheck disable=SC2086
17
- "$NPM_BIN" install -g --force $AI_TOOLS_NPM_PACKAGES
22
+ read -r -a npm_packages <<<"$AI_TOOLS_NPM_PACKAGES"
23
+ "$NPM_BIN" install -g --force "${npm_packages[@]}"
24
+ fi
25
+
26
+ # corepack and pnpm both own the pnpm/pnpx shims; install pnpm last so npm's
27
+ # current pnpm package remains the command users execute.
28
+ if [ -n "$AI_TOOLS_PNPM_PACKAGE" ]; then
29
+ read -r -a pnpm_packages <<<"$AI_TOOLS_PNPM_PACKAGE"
30
+ "$NPM_BIN" install -g --force "${pnpm_packages[@]}"
31
+ fi
32
+
33
+ CLAUDE_INSTALL="$("$NPM_BIN" root -g)/@anthropic-ai/claude-code/install.cjs"
34
+ if [ -f "$CLAUDE_INSTALL" ]; then
35
+ /usr/local/bin/node "$CLAUDE_INSTALL"
18
36
  fi
19
37
 
20
38
  if [ -n "$AI_TOOLS_APT_PACKAGES" ] && command -v "$APT_GET_BIN" >/dev/null 2>&1; then
21
- # shellcheck disable=SC2086
22
- "$APT_GET_BIN" install --only-upgrade -y $AI_TOOLS_APT_PACKAGES
39
+ read -r -a apt_packages <<<"$AI_TOOLS_APT_PACKAGES"
40
+ "$APT_GET_BIN" install --only-upgrade -y "${apt_packages[@]}"
23
41
  fi