Skip to content

Define GH_AW_HOME at job level to eliminate fallback macro repetition#19823

Merged
pelikhan merged 2 commits intoportable-gh-aw-homefrom
copilot/sub-pr-19744
Mar 6, 2026
Merged

Define GH_AW_HOME at job level to eliminate fallback macro repetition#19823
pelikhan merged 2 commits intoportable-gh-aw-homefrom
copilot/sub-pr-19744

Conversation

Copy link
Contributor

Copilot AI commented Mar 6, 2026

Every shell run: step and JS require() call repeated the fallback macro ${GH_AW_HOME:-/opt/gh-aw} / (process.env.GH_AW_HOME || '/opt/gh-aw'). Defining the variable once at the job level removes that noise from every step.

Constants

  • GhAwHome: ${GH_AW_HOME:-/opt/gh-aw}${GH_AW_HOME}
  • GhAwHomeJS: (process.env.GH_AW_HOME || '/opt/gh-aw')process.env.GH_AW_HOME

Job-level env: GH_AW_HOME: /opt/gh-aw added to all consuming jobs

  • activationcompiler_activation_job.go
  • agentcompiler_main_job.go (env map now always initialized)
  • conclusionnotify_comment.go
  • safe_outputscompiler_safe_outputs_job.go
  • update_cache_memorycache.go
  • push_repo_memoryrepo_memory.go
  • Custom safe_jobssafe_jobs.go
  • Maintenance workflow jobs (close-expired-entities, run_operation, compile-workflows, secret-validation) — maintenance_workflow.go

Note: DefaultGhAwMount (\${GH_AW_HOME:-/opt/gh-aw}:\${GH_AW_HOME:-/opt/gh-aw}:ro) is intentionally unchanged — it's a Docker volume mount spec evaluated in a different context.

All 167 workflow lock files recompiled; zero occurrences of the old :-/opt/gh-aw fallback remain in generated YAML.


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Mar 6, 2026

Just as a heads up, I was blocked by some firewall rules while working on your feedback. Expand below for details.

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • https://api.github.com/graphql
    • Triggering command: /usr/bin/gh /usr/bin/gh api graphql -f query=query($owner: String!, $name: String!) { repository(owner: $owner, name: $name) { hasDiscussionsEnabled } } -f owner=github -f name=gh-aw lish_assets_testinit ache/uv/0.10.8/x86_64/sed git rev-�� --show-toplevel sed /usr/bin/git .GH_AW_HOME || &#39;git m_member_test.gorev-parse 64/pkg/tool/linu--show-toplevel git (http block)
    • Triggering command: /usr/bin/gh /usr/bin/gh api graphql -f query=query($owner: String!, $name: String!) { repository(owner: $owner, name: $name) { hasDiscussionsEnabled } } -f owner=github -f name=gh-aw sed /usr/bin/git git rev-�� --show-toplevel git /usr/bin/git --show-toplevel ache/go/1.25.0/xrev-parse /usr/bin/git git (http block)
    • Triggering command: /usr/bin/gh /usr/bin/gh api graphql -f query=query($owner: String!, $name: String!) { repository(owner: $owner, name: $name) { hasDiscussionsEnabled } } -f owner=github -f name=gh-aw git /usr/bin/git git rev-�� --show-toplevel git /usr/bin/git --show-toplevel git /usr/bin/git git (http block)
  • https://api.github.com/repos/actions/ai-inference/git/ref/tags/v1
    • Triggering command: /usr/bin/gh gh api /repos/actions/ai-inference/git/ref/tags/v1 --jq .object.sha 64/bin/sed sed /usr/bin/git pt/gh-aw&#39;) &#43;|progit dation_integratirev-parse /opt/hostedtoolc--show-toplevel git rev-�� it/ref/tags/v7 sed /opt/hostedtoolcache/node/24.14.0/x64/bin/node /opt/gh-aw&#39;) &#43;|pgit gration_test.go nfig/composer/ve--show-toplevel node (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/ai-inference/git/ref/tags/v1 --jq .object.sha --show-toplevel git /usr/bin/git --show-toplevel x_amd64/compile /usr/bin/git git rev-�� --show-toplevel git /usr/bin/git pload-artifact/ggit sed /usr/bin/infocmp--show-toplevel git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/ai-inference/git/ref/tags/v1 --jq .object.sha --show-toplevel git /usr/bin/git --show-toplevel git /usr/bin/git git rev-�� --show-toplevel git /opt/hostedtoolcache/node/24.14.0/x64/bin/node pload-artifact/ggit git /usr/bin/git node (http block)
  • https://api.github.com/repos/actions/checkout/git/ref/tags/v3
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v3 --jq .object.sha runs/20260306-085318-15303/test-2400686256/custom/workflows stmain.go /usr/bin/git cess.env.GH_AW_Hgit or_test.go /home/REDACTED/.do--show-toplevel git rev-�� --show-toplevel sed /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/vet TempFolder|TestSgit test.go tnet/tools/sed /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v3 --jq .object.sha --show-toplevel git /usr/bin/git /tmp/TestCompilegit config (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v3 --jq .object.sha --show-toplevel git 0/x64/bin/node )&#34; git /usr/bin/git git cjs --show-toplevel git /usr/bin/git --show-toplevel git /usr/bin/git git (http block)
  • https://api.github.com/repos/actions/checkout/git/ref/tags/v5
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v5 --jq .object.sha s|(process.env.GH_AW_HOME || &#39;/opt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g pkg/workflow/job_dependencies_test.go /home/REDACTED/go/bin/sed OME &#43;|g _integration_tesinit ache/uv/0.10.8/x86_64/sed sed -i safeoutputs\|safeoutputs.*entrypointArgs pkg/workflow/map_helpers_test.go cal/bin/bash OME &#43;|g z_test.go k/_temp/uv-pytho--show-toplevel bash (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v5 --jq .object.sha user.name Test User 9075345/b435/vet.cfg H_AW_HOME || &#39;/ogit _dependencies_terev-parse nfig/composer/ve--show-toplevel git rev-�� --git-dir sed /tmp/go-build2549075345/b433/workflow.test H_AW_HOME || &#39;/ogit gin_mcp_integratrev-parse k/_temp/ghcca-no--show-toplevel /tmp/go-build2549075345/b433/workflow.test (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v5 --jq .object.sha --show-toplevel sed /usr/bin/git s|(process.env.Ggit pkg/workflow/coprev-parse 64/pkg/tool/linu--show-toplevel git rev-�� pload-artifact/git/ref/tags/v4 64/pkg/tool/linux_amd64/vet /usr/bin/git 7204/001/stabiligit pkg/workflow/mcprev-parse tnet/tools/bash git (http block)
  • https://api.github.com/repos/actions/checkout/git/ref/tags/v6
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v6 --jq .object.sha tags/v5 -extld=gcc /usr/bin/git pt/gh-aw&#39;) &#43;|progit st.go nfig/composer/ve--show-toplevel git conf�� user.name Test User /usr/bin/git ointArgs (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v6 --jq .object.sha xterm-color sed /usr/bin/git pt/gh-aw&#39;) &#43;|progit o \) \&#43;/process.en--show-toplevel git rev-�� --show-toplevel t.go /usr/bin/git pt/gh-aw&#39;) &#43;|progit go 86_64/sed git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v6 --jq .object.sha --show-toplevel yrL57UAVUFNA /usr/bin/git s|(process.env.Ggit pkg/workflow/pacrev-parse bash git rev-�� --show-toplevel sed /usr/bin/git s|(process.env.Ggit pkg/workflow/comrev-parse iptables git (http block)
  • https://api.github.com/repos/actions/download-artifact/git/ref/tags/v8
    • Triggering command: /usr/bin/gh gh api /repos/actions/download-artifact/git/ref/tags/v8 --jq .object.sha 53/001/test-frontmatter-with-nested-objects.md piler_events_test.go tartedAt,updatedAt,event,headBranch,headSha,displayTitle OME &#43;|g ion_integration_rev-parse k/_temp/uv-pytho--show-toplevel 64/pkg/tool/linux_amd64/vet --no�� 3083294127 sed .cfg OME &#43;|g test.go de/node/bin/sed bash (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/download-artifact/git/ref/tags/v8 --jq .object.sha --noprofile sed /home/REDACTED/work/_temp/ghcca-node/node/bin/bash OME &#43;|g o n-dir/sed bash --no�� --noprofile sed ache/go/1.25.0/x64/pkg/tool/linux_amd64/compile OME &#43;|g r_config_test.gorev-parse d ache/go/1.25.0/x64/pkg/tool/linux_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/download-artifact/git/ref/tags/v8 --jq .object.sha --noprofile sed /home/REDACTED/.local/bin/bash OME &#43;|g job_test.go ache/uv/0.10.8/x--show-toplevel bash --no�� 5318-15303/test-3083294127 sed /usr/sbin/bash _HOME &#43;|g ation_test.go /home/REDACTED/.co--show-toplevel bash (http block)
  • https://api.github.com/repos/actions/github-script/git/ref/tags/v8
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v8 --jq .object.sha pt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g piler_orchestrator_tools_test.go ndor/bin/sed OME &#43;|g nsion_test.go n-dir/sed sed -i pt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g st.go 64/bin/sed OME &#43;|g ate_pull_requestrev-parse k/_temp/ghcca-no--show-toplevel sed (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v8 --jq .object.sha rocess.env.GH_AW_HOME &#43;|g st.go p/bin/sed OME &#43;|g st.go ache/node/24.14.--show-toplevel sed -i pt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g ion_test.go 86_64/sed OME &#43;|g test.go rgo/bin/sed sed (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v8 --jq .object.sha rocess.env.GH_AW_HOME &#43;|g g_test.go d OME &#43;|g r_test.go n-dir/sed sed -i pt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g st.go p/bin/sed OME &#43;|g o ache/node/24.14./tmp/go-build2549075345/b392/constants.test sed (http block)
  • https://api.github.com/repos/actions/setup-go/git/ref/tags/v4
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-go/git/ref/tags/v4 --jq .object.sha --show-toplevel 9075345/b422/_testmain.go /usr/bin/git -c=4 -nolocalimports -importcfg git conf�� --get remote.origin.url /usr/bin/git pt/gh-aw&#39;) &#43;|progit (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-go/git/ref/tags/v4 --jq .object.sha --show-toplevel git /usr/bin/git --show-toplevel x_amd64/cgo /usr/bin/git git rev-�� --show-toplevel git /usr/bin/git ownload-artifactgit x_amd64/vet /usr/bin/git git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-go/git/ref/tags/v4 --jq .object.sha --show-toplevel git ache/node/24.14.0/x64/bin/node --show-toplevel docker /usr/bin/git git _lab�� --show-toplevel git /usr/bin/git --show-toplevel git /usr/bin/infocmp--show-toplevel git (http block)
  • https://api.github.com/repos/actions/setup-node/git/ref/tags/v4
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-node/git/ref/tags/v4 --jq .object.sha --show-toplevel -tests /usr/bin/git pt/gh-aw&#39;) &#43;|progit st.go 0/x64/bin/sed git remo�� it/ref/tags/v7 origin /usr/bin/git pt/gh-aw&#39;) &#43;|progit (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-node/git/ref/tags/v4 --jq .object.sha --show-toplevel git /usr/bin/git bin/sed x_amd64/compile /usr/bin/git git rev-�� --show-toplevel git /usr/bin/git --show-toplevel x_amd64/vet /usr/bin/git git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-node/git/ref/tags/v4 --jq .object.sha --show-toplevel git ache/node/24.14.0/x64/bin/node --show-toplevel gh /usr/bin/gh git _lab�� it/ref/tags/v7 gh /usr/bin/git /repos/actions/ugit --jq /usr/bin/git git (http block)
  • https://api.github.com/repos/actions/upload-artifact/git/ref/tags/v4
    • Triggering command: /usr/bin/gh gh api /repos/actions/upload-artifact/git/ref/tags/v4 --jq .object.sha SameOutput3861157204/001/stability-test.md sed /home/REDACTED/.dotnet/tools/bash OME &#43;|g test.go de/node/bin/sed bash --no�� --noprofile sed 9075345/b387/vet.cfg _HOME &#43;|g ine_agent_importrev-parse n-dir/sed git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/upload-artifact/git/ref/tags/v4 --jq .object.sha ature-branch.patch git /home/REDACTED/.local/bin/node user.email test@example.comrev-parse /usr/bin/git node /opt�� install --package-lock-only /usr/bin/git --show-toplevel sed /opt/hostedtoolc--show-toplevel git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/upload-artifact/git/ref/tags/v4 --jq .object.sha --show-toplevel git 0/x64/bin/node --show-toplevel git /usr/bin/git git ance�� HEAD git 0/x64/bin/node --show-toplevel git /usr/bin/git git (http block)
  • https://api.github.com/repos/actions/upload-artifact/git/ref/tags/v7
    • Triggering command: /usr/bin/gh gh api /repos/actions/upload-artifact/git/ref/tags/v7 --jq .object.sha s|(process.env.GH_AW_HOME || &#39;/opt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g pkg/workflow/map_helpers_test.go 64/pkg/tool/linux_amd64/compile OME &#43;|g z_test.go cal/bin/sed 64/pkg/tool/linux_amd64/compile --no�� --noprofile sed cal/bin/bash OME &#43;|g ers_test.go 86_64/sed bash (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/upload-artifact/git/ref/tags/v7 --jq .object.sha s|(process.env.GH_AW_HOME || &#39;/o-p pkg/workflow/claude_engine_test.main 64/pkg/tool/linux_amd64/vet OME &#43;|g o ache/uv/0.10.8/x--show-toplevel 64/pkg/tool/linux_amd64/vet -i s|(process\.env\.GH_AW_HOME || &#39;go1.25.0 pkg/workflow/playwright_mcp_inte-c=4 .cfg OME &#43;|g ion_integration_rev-parse n-dir/sed bash (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/upload-artifact/git/ref/tags/v7 --jq .object.sha s|(process.env.GH_AW_HOME || &#39;/o-s pkg/workflow/github_toolset_vali-w 64/pkg/tool/linux_amd64/vet OME &#43;|g .go de/node/bin/sed 64/pkg/tool/linux_amd64/vet -i 53/001/test-frontmatter-with-arrays.md .cfg sh OME &#43;|g set_test.go ache/uv/0.10.8/x--show-toplevel bash (http block)
  • https://api.github.com/repos/astral-sh/setup-uv/git/ref/tags/eac588ad8def6316056a12d4907a9d4d84ff7a3b
    • Triggering command: /usr/bin/gh gh api /repos/astral-sh/setup-uv/git/ref/tags/eac588ad8def6316056a12d4907a9d4d84ff7a3b --jq .object.sha -json GO111MODULE 64/bin/go GOINSECURE GOMOD erignore go env -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/1/artifacts
    • Triggering command: /usr/bin/gh gh run download 1 --dir test-logs/run-1 hub_toolsets_tes-w /home/REDACTED/go/-buildmode=exe OME &#43;|g ion_test.go ache/go/1.25.0/xuser.email sed -i .GH_AW_HOME || &#39;/opt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g e_outputs_domains_validation_test.go 64/bin/bash OME &#43;|g tegration_test.grev-parse rgo/bin/sed sed (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/12345/artifacts
    • Triggering command: /usr/bin/gh gh run download 12345 --dir test-logs/run-12345 pile_outputs_lab-ifaceassert rgo/bin/sed OME &#43;|g _tool_validationrev-parse ed sed -i .GH_AW_HOME || &#39;/opt/gh-aw&#39;) &#43;|pgo1.25.0 e_outputs_domains_validation_tes-c=4 ache/node/24.14.0/x64/bin/bash OME &#43;|g tegration_test.grev-parse bin/sed sed (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/12346/artifacts
    • Triggering command: /usr/bin/gh gh run download 12346 --dir test-logs/run-12346 pile_outputs_lab-test.run=^Test d OME &#43;|g _tool_validationrev-parse sed sed -i .GH_AW_HOME || &#39;/opt/gh-aw&#39;) &#43;|premote.origin.url e_outputs_domains_validation_test.go ache/go/1.25.0/x64/bin/bash OME &#43;|g tegration_test.grev-parse cal/bin/sed sed (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/2/artifacts
    • Triggering command: /usr/bin/gh gh run download 2 --dir test-logs/run-2 hub_toolsets_test.go n-dir/bash OME &#43;|g ion_test.go 86_64/sed sed -i hub/workflows _comments_test.go /home/REDACTED/.local/bin/sed OME &#43;|g n_test.go de/node/bin/sed sed (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/3/artifacts
    • Triggering command: /usr/bin/gh gh run download 3 --dir test-logs/run-3 hub_toolsets_test.go k/_temp/uv-python-dir/sed OME &#43;|g ion_test.go ndor/bin/sed sed -i .GH_AW_HOME || &#39;/opt/gh-aw&#39;) &#43;|p-c=4 _comments_test.go 0/x64/bin/bash OME &#43;|g tegration_test.ginit k/_temp/uv-python-dir/sed sed (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/4/artifacts
    • Triggering command: /usr/bin/gh gh run download 4 --dir test-logs/run-4 _test.go x_amd64/compile OME &#43;|g ion_test.go k/_temp/ghcca-no--show-toplevel x_amd64/compile -i .GH_AW_HOME || &#39;/opt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g _comments_test.go de/node/bin/bash OME &#43;|g tegration_test.grev-parse 64/bin/sed sed (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/5/artifacts
    • Triggering command: /usr/bin/gh gh run download 5 --dir test-logs/run-5 hub_toolsets_test.go cal/bin/sed OME &#43;|g ion_test.go n-dir/sed sed -i hub/workflows _comments_test.go ash OME &#43;|g n_test.go 0/x64/bin/sed sed (http block)
  • https://api.github.com/repos/github/gh-aw/actions/workflows
    • Triggering command: /usr/bin/gh gh workflow list --json name,state,path rocess.env.GH_AW_HOME &#43;|g _reviewers_integration_test.go e9b83a7df1673f1d-d OME &#43;|g (http block)
    • Triggering command: /usr/bin/gh gh run list --json databaseId,number,url,status,conclusion,workflowName,createdAt,startedAt,updatedAt,event,headBranch,headSha,displayTitle --workflow nonexistent-workflow-12345 --limit 100 o p/bin/sed ${GH_AW_HOME}:ro&#39;, &#39;${GH_AW -i pt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g t.go cal/bin/sed OME &#43;|g t.go ache/go/1.25.0/x-bool sed (http block)
    • Triggering command: /usr/bin/gh gh run list --json databaseId,number,url,status,conclusion,workflowName,createdAt,startedAt,updatedAt,event,headBranch,headSha,displayTitle --workflow nonexistent-workflow-12345 --limit 6 (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/a70c5eada06553e3510ac27f2c3bda9d3705bccb
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/a70c5eada06553e3510ac27f2c3bda9d3705bccb --jq .object.sha -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go env -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/v1.0.0
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.0.0 --jq .object.sha .GH_AW_HOME || &#39;--detach ywright_mcp_integration_test.go cal/bin/bash OME &#43;|g .go ache/uv/0.10.8/x--show-toplevel sed -i 2222962931/.github/workflows pkg/workflow/pip_test.go /opt/hostedtoolcache/uv/0.10.8/x-importcfg OME &#43;|g l_test.go 86_64/sed sed (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.0.0 --jq .object.sha --show-toplevel bash /usr/bin/git 5318-15303/test-git sed .cfg git rev-�� --show-toplevel /usr/lib/sysstat/sadc /usr/bin/git /v2.0.0 -S 64/pkg/tool/linu--show-toplevel git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.0.0 --jq .object.sha --show-toplevel git /usr/bin/git --show-toplevel git /opt/hostedtoolcache/node/24.14.--show-toplevel git rev-�� --show-toplevel node k/_temp/uv-python-dir/node install --package-lock-ojs/fuzz_sanitize_label_harness.cjs /usr/bin/git git (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/v1.2.3
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.2.3 --jq .object.sha pt/gh-aw&#39;) &#43;|pro-errorsas ivation_outputs_-ifaceassert n-dir/sed OME &#43;|g go de/node/bin/sed sed -i pt/gh-aw&#39;) &#43;|pro-p (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/v2.0.0
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v2.0.0 --jq .object.sha pt/gh-aw&#39;) &#43;|pro-errorsas ivation_outputs_-ifaceassert nfig/composer/ve-nilfunc OME &#43;|g ker_predownload_-atomic /home/REDACTED/wor-bool sed -i pt/gh-aw&#39;) &#43;|pro-errorsas (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v2.0.0 --jq .object.sha pt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g ivation_outputs_always_declared_test.go de/node/bin/sed OME &#43;|g ker_predownload_-atomic 86_64/sed sed -i pt/gh-aw&#39;) &#43;|pro-errorsas (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v2.0.0 --jq .object.sha pt/gh-aw&#39;) &#43;|process.env.GH_AW_H1 test.go ache/node/24.14.0/x64/bin/sed OME &#43;|g ker_predownload_-atomic 64/bin/sed sed -i pt/gh-aw&#39;) &#43;|pro-errorsas (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/v3.0.0
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v3.0.0 --jq .object.sha pt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g ivation_outputs_always_declared_test.go 64/bin/sed OME &#43;|g ker_predownload_-atomic d sed -i pt/gh-aw&#39;) &#43;|pro-errorsas (http block)
  • https://api.github.com/repos/githubnext/agentics/git/ref/tags/
    • Triggering command: /usr/bin/gh gh api /repos/githubnext/agentics/git/ref/tags/# --jq .object.sha 8342239/b383/_pkGOINSECURE GO111MODULE 64/bin/go GOINSECURE b/gh-aw/pkg/cli GOMODCACHE go env he4O/-Bh5GFzuEG0GOSUMDB GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE 8342239/b383/imp-f (http block)
  • https://api.github.com/repos/nonexistent/action/git/ref/tags/v999.999.999
    • Triggering command: /usr/bin/gh gh api /repos/nonexistent/action/git/ref/tags/v999.999.999 --jq .object.sha tmatter-with-arrays.md ywright_mcp_integration_test.go 0/x64/bin/bash OME &#43;|g .go bin/sed sed -i s|(process.env.GH_AW_HOME || &#39;/opt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g pkg/workflow/pip_test.go x_amd64/vet OME &#43;|g l_test.go d x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/nonexistent/action/git/ref/tags/v999.999.999 --jq .object.sha --show-toplevel bash 64/bin/node --noprofile sed /opt/hostedtoolc--show-toplevel git 0/x6�� --show-toplevel bash /usr/bin/git --noprofile sed 64/pkg/tool/linu--show-toplevel git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/nonexistent/action/git/ref/tags/v999.999.999 --jq .object.sha --show-toplevel git /usr/bin/git --show-toplevel git /opt/hostedtoolcache/node/24.14.--show-toplevel git rev-�� --show-toplevel /opt/hostedtoolcache/node/24.14.0/x64/bin/npm cal/bin/node --package-lock-onode git /usr/bin/git git (http block)
  • https://api.github.com/repos/nonexistent/repo/actions/runs/12345
    • Triggering command: /usr/bin/gh gh run view 12345 --repo nonexistent/repo --json status,conclusion OME &#43;|g ditional_test.gorev-parse ndor/bin/sed x_amd64/link -i .GH_AW_HOME || &#39;/opt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g m_member_test.go kflow.test OME &#43;|g (http block)
  • https://api.github.com/repos/owner/repo/actions/workflows
    • Triggering command: /usr/bin/gh gh workflow list --json name,state,path --repo owner/repo k/_temp/ghcca-node/node/bin/sed OME &#43;|g sions_test.go ndor/bin/sed sed -i pt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g el_trigger_parser_test.go 86_64/sed h = re.search(b&#39;bash o k/_temp/ghcca-no--noprofile sed (http block)
    • Triggering command: /usr/bin/gh gh workflow list --json name,state,path --repo owner/repo 86_64/sed OME &#43;|g ration_test.go nfig/composer/ve--noprofile sed -i pt/gh-aw&#39;) &#43;|process.env.GH_AW_HOME &#43;|g st.go de/node/bin/sed OME &#43;|g o nfig/composer/ve--noprofile sed (http block)
  • https://api.github.com/repos/owner/repo/contents/file.md
    • Triggering command: /tmp/go-build2549075345/b383/cli.test /tmp/go-build2549075345/b383/cli.test -test.testlogfile=/tmp/go-build2549075345/b383/testlog.txt -test.paniconexit0 -test.v=true -test.parallel=4 -test.timeout=10m0s -test.run=^Test -test.short=true OME &#43;|g st.go ache/go/1.25.0/x--noprofile sed -i rocess.env.GH_AW_HOME &#43;|g _test.go ache/node/24.14.0/x64/bin/sed OME &#43;|g r_test.go p/bin/sed sed (http block)
  • https://api.github.com/repos/test-owner/test-repo/actions/secrets
    • Triggering command: /usr/bin/gh gh api /repos/test-owner/test-repo/actions/secrets --jq .secrets[].name rocess.env.GH_AW_HOME &#43;|g _reviewers_integration_test.go ache/node/24.14.0/x64/bin/sed OME &#43;|g (http block)

If you need me to access, download, or install something from one of these locations, you can either:

Copilot AI changed the title [WIP] Update job-level environment variable for GH_AW_HOME Define GH_AW_HOME at job level to eliminate fallback macro repetition Mar 6, 2026
@pelikhan pelikhan marked this pull request as ready for review March 6, 2026 09:52
Copilot AI review requested due to automatic review settings March 6, 2026 09:52
@pelikhan pelikhan merged commit 442a051 into portable-gh-aw-home Mar 6, 2026
@pelikhan pelikhan deleted the copilot/sub-pr-19744 branch March 6, 2026 09:52
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR centralizes the GH_AW_HOME default (/opt/gh-aw) by defining it once at the job level, removing repeated fallback expressions in generated shell run: steps and JS require() statements across compiled workflows and golden fixtures.

Changes:

  • Updated GhAwHome / GhAwHomeJS constants to use ${GH_AW_HOME} / process.env.GH_AW_HOME (no inline fallbacks).
  • Ensured consuming jobs initialize job-level env with GH_AW_HOME: /opt/gh-aw (including main/activation/conclusion/safe outputs/cache/repo memory/custom safe jobs/maintenance workflows).
  • Recompiled and updated workflow lock files and golden test fixtures; updated tests asserting the old fallback strings.

Reviewed changes

Copilot reviewed 48 out of 207 changed files in this pull request and generated no comments.

Show a summary per file
File Description
pkg/workflow/testdata/wasm_golden/TestWasmGolden_CompileFixtures/with-imports.golden Golden YAML updated to include job-level GH_AW_HOME and remove fallback usage in shell/JS.
pkg/workflow/testdata/wasm_golden/TestWasmGolden_CompileFixtures/smoke-copilot.golden Golden YAML updated to include job-level GH_AW_HOME and remove fallback usage in shell/JS.
pkg/workflow/testdata/wasm_golden/TestWasmGolden_CompileFixtures/basic-copilot.golden Golden YAML updated to include job-level GH_AW_HOME and remove fallback usage in shell/JS.
pkg/workflow/template_rendering_test.go Test expectations updated to match new require(process.env.GH_AW_HOME + ...) strings.
pkg/workflow/template_injection_validation_test.go Test strings updated to reference ${GH_AW_HOME} without fallback.
pkg/workflow/temp_folder_test.go Test expectation updated to ${GH_AW_HOME}/prompts/... path.
pkg/workflow/step_summary_test.go Test expectations updated to match new JS require path concatenation.
pkg/workflow/step_order_validation_test.go Updated test path to ${GH_AW_HOME}/... (no fallback).
pkg/workflow/step_order_validation_integration_test.go Updated integration test path to ${GH_AW_HOME}/... (no fallback).
pkg/workflow/setup_action_paths.go Updated path constants to rely on GH_AW_HOME being set at job level (no fallback).
pkg/workflow/secret_validation_test.go Updated test expectations for secret validation script paths without fallback.
pkg/workflow/safe_jobs.go Custom safe jobs now set GH_AW_HOME at the job level by default.
pkg/workflow/repo_memory_test.go Updated expected script invocation path to ${GH_AW_HOME}/....
pkg/workflow/repo_memory_integration_test.go Updated expected JS require + bash paths to use GH_AW_HOME without fallback.
pkg/workflow/repo_memory.go Push repo memory job now sets GH_AW_HOME in job env.
pkg/workflow/prompts_test.go Updated expected prompt file references to ${GH_AW_HOME}/prompts/....
pkg/workflow/pr_checkout_test.go Updated expected PR prompt references to ${GH_AW_HOME}/prompts/....
pkg/workflow/notify_comment.go Conclusion job now sets GH_AW_HOME in job env.
pkg/workflow/mcp_config_refactor_test.go Updated expected MCP config entrypoint/args paths to ${GH_AW_HOME}/... (mount fallback intentionally unchanged).
pkg/workflow/maintenance_workflow.go Maintenance workflow templates updated to include job-level GH_AW_HOME.
pkg/workflow/main_job_env_test.go Updated tests to expect GH_AW_HOME always present in main job env.
pkg/workflow/inference_access_error_test.go Updated expected script path to ${GH_AW_HOME}/....
pkg/workflow/git_config_test.go Updated expected clean-credentials script path to ${GH_AW_HOME}/....
pkg/workflow/firewall_version_pinning_test.go Updated expected install script path to ${GH_AW_HOME}/....
pkg/workflow/engine_includes_test.go Updated expected Copilot installer script path to ${GH_AW_HOME}/....
pkg/workflow/engine_helpers_shared_test.go Updated expected MCP start script path to ${GH_AW_HOME}/....
pkg/workflow/docker_predownload_test.go Updated expected docker predownload script path to ${GH_AW_HOME}/....
pkg/workflow/detection_success_test.go Updated expected JS require path to process.env.GH_AW_HOME + ....
pkg/workflow/copilot_installer_test.go Updated expected Copilot install script path to ${GH_AW_HOME}/....
pkg/workflow/compiler_yaml_main_job_test.go Updated expected temp dir creation script path to ${GH_AW_HOME}/....
pkg/workflow/compiler_safe_outputs_steps_test.go Updated expected handler require paths to process.env.GH_AW_HOME + ....
pkg/workflow/compiler_safe_outputs_job.go Safe outputs job-level env now explicitly includes GH_AW_HOME.
pkg/workflow/compiler_main_job.go Main agent job now always initializes job env (including GH_AW_HOME).
pkg/workflow/compiler_activation_job.go Activation job now sets GH_AW_HOME in job env.
pkg/workflow/codex_engine_test.go Updated expected MCP start script path to ${GH_AW_HOME}/....
pkg/workflow/cache_memory_integration_test.go Updated expected prompt reference to ${GH_AW_HOME}/....
pkg/workflow/cache.go Cache update job now always includes GH_AW_HOME and conditionally adds sanitized workflow ID.
pkg/workflow/aw_info_tmp_test.go Updated expected JS require path to process.env.GH_AW_HOME + ....
pkg/workflow/agentic_output_test.go Updated expected safe-outputs env exports to ${GH_AW_HOME}/... paths.
.github/workflows/test-workflow.lock.yml Recompiled lockfile: added job-level GH_AW_HOME and removed fallback usage.
.github/workflows/metrics-collector.lock.yml Recompiled lockfile: added job-level GH_AW_HOME and removed fallback usage.
.github/workflows/issue-triage-agent.lock.yml Recompiled lockfile: added job-level GH_AW_HOME and removed fallback usage.
.github/workflows/issue-arborist.lock.yml Recompiled lockfile: added job-level GH_AW_HOME and removed fallback usage.
.github/workflows/firewall.lock.yml Recompiled lockfile: added job-level GH_AW_HOME and removed fallback usage.
.github/workflows/example-permissions-warning.lock.yml Recompiled lockfile: added job-level GH_AW_HOME and removed fallback usage.
.github/workflows/daily-syntax-error-quality.lock.yml Recompiled lockfile: added job-level GH_AW_HOME and removed fallback usage.
.github/workflows/daily-malicious-code-scan.lock.yml Recompiled lockfile: added job-level GH_AW_HOME and removed fallback usage.
.github/workflows/daily-fact.lock.yml Recompiled lockfile: added job-level GH_AW_HOME and removed fallback usage.
.github/workflows/codex-github-remote-mcp-test.lock.yml Recompiled lockfile: added job-level GH_AW_HOME and removed fallback usage.
.github/workflows/chroma-issue-indexer.lock.yml Recompiled lockfile: added job-level GH_AW_HOME and removed fallback usage.
.github/workflows/bot-detection.lock.yml Recompiled lockfile: added job-level GH_AW_HOME and removed fallback usage.
.github/workflows/agentics-maintenance.yml Maintenance workflow updated to define GH_AW_HOME at job level and simplify require() paths.
.github/workflows/ace-editor.lock.yml Recompiled lockfile: added job-level GH_AW_HOME and removed fallback usage.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants