Skip to content

Commit

Permalink
Prioritises current nimble (#1358)
Browse files Browse the repository at this point in the history
* Prioritises current nimble

* Adjusts test to change
  • Loading branch information
jmgomez authored Mar 5, 2025
1 parent 0ac2b44 commit ec91888
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/nimble.nim
Original file line number Diff line number Diff line change
Expand Up @@ -2326,7 +2326,7 @@ proc getAlteredPath(options: Options): string =
paths.add folder
paths.reverse
let parentDir = options.nimBin.get.path.parentDir
result = fmt "{paths.join(separator)}{separator}{parentDir}{separator}{getEnv(\"PATH\")}"
result = fmt "{getAppDir()}{separator}{paths.join(separator)}{separator}{parentDir}{separator}{getEnv(\"PATH\")}"

proc shellenv(options: var Options) =
setVerbosity(SilentPriority)
Expand Down
4 changes: 2 additions & 2 deletions tests/tshellenv.nim
Original file line number Diff line number Diff line change
Expand Up @@ -32,5 +32,5 @@ suite "Shell env":
check prefix == "export PATH"


check dirs[0].extractFileName == "shellenv"
check dirs[1].extractFileName == "testutils-0.5.0-756d0757c4dd06a068f9d38c7f238576ba5ee897"
check dirs[1].extractFileName == "shellenv"
check dirs[2].extractFileName == "testutils-0.5.0-756d0757c4dd06a068f9d38c7f238576ba5ee897"

0 comments on commit ec91888

Please sign in to comment.