Skip to content

Fix unbound variable error in install script#60

Merged
Aaronontheweb merged 1 commit intodevfrom
fix/install-script-tmpdir
May 5, 2026
Merged

Fix unbound variable error in install script#60
Aaronontheweb merged 1 commit intodevfrom
fix/install-script-tmpdir

Conversation

@Aaronontheweb
Copy link
Copy Markdown
Contributor

Summary

  • Move tmp_dir from local function scope to script-level TMP_DIR so the EXIT trap can reference it after main() returns
  • With set -u (nounset), the local variable was out of scope when the trap fired, causing an "unbound variable" error on exit

Test plan

  • Ran install-skillserver.sh locally — installs skillserver 0.3.0 cleanly with no errors
  • Verified skillserver --version works after install

Move tmp_dir from local function scope to script scope so the EXIT
trap can reference it after main() returns. With set -u (nounset),
the local variable was out of scope when the trap fired.
@Aaronontheweb Aaronontheweb enabled auto-merge (squash) May 5, 2026 02:09
@Aaronontheweb Aaronontheweb merged commit 048ed58 into dev May 5, 2026
7 checks passed
@Aaronontheweb Aaronontheweb deleted the fix/install-script-tmpdir branch May 5, 2026 02:10
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.

1 participant