fix(install): detect Scripts/bin dir and offer to add it to PATH#19
Merged
Conversation
The "'aim' is not recognized" / "command not found" error right after install is almost always pip placing the console script in a folder that is not on PATH. Both one-line installers now locate that folder via sysconfig, and when running interactively offer to append it to the user PATH (also updating the current session so 'aim' works right away). Non-interactive runs print manual instructions instead of changing PATH. Document the fix plus a no-PATH `python -m aim.aim_cli` workaround in both README.md and README-VI.md. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
phuonghx
added a commit
that referenced
this pull request
Jun 14, 2026
fix(install): detect Scripts/bin dir and offer to add it to PATH
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Right after installation, users frequently hit
'aim' is not recognized(Windows) oraim: command not found(macOS/Linux). The cause is almost always pip placing theaimexecutable in a Scripts (Windows) / bin (Unix) folder that is not onPATH.Changes
install.ps1/install.sh: after install, auto-detect the folder that holdsaimviasysconfig(user scheme first, also checking foraim.exe/aim).PATH-> report OK.[Y/n]to add it to the user PATH, and update the current session immediately soaimworks right away.install.shreads the answer via/dev/ttyso it still works when installed throughcurl ... | bash, and picks the correct rc file (.zshrc/.bashrc/.bash_profile/.profile).README.md/README-VI.md: add a troubleshooting section for this error, plus a no-PATH way to run it:python -m aim.aim_cli init.Notes
set +e(sh) so minor errors don't break the already-successful install.