You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: use platform-specific name for temp/cleanup in shared directories
Always download to the platform-specific binary name (coder-linux-amd64)
for temp files, old backups, signatures, and lock files. After a
successful download, rename the result to the user's configured file
name while still holding the lock to avoid races with other windows.
Scoped rmOld to only clean files prefixed with the binary basename so
it does not accidentally remove unrelated files when the target
directory is shared (e.g. /usr/bin).
Additional improvements:
- Rename cliUtils.name() to fullName() to pair with simpleName()
- Replace ResolvedBinary kind "file"/"dir" with source "file-path"/"directory"
to clarify that stat always describes the binary, not the directory
- Fix binaryDestination description: file paths are version-checked and
updated on mismatch, not used without downloading
- Update resolveBinaryPath JSDoc to remove misleading "as-is" language
- Add fallback path to error handler so file-path destinations check
the user's original binary when the download path has no usable binary
- Simplify handleAnyBinaryFailure with tryCandidate closure and deferred
findOldBinaries to avoid unnecessary I/O when earlier candidates match
- On error recovery, rename fallback to resolved.binPath so the binary
always ends up where the user expects
- Add "starting download" back to the no-binary-found log message
- Improve test coverage: file destination error fallback, simple name
error fallback, platform-specific file destination, old backup restore
- Unify test structure: shared disableSignatureVerification in top-level
beforeEach, shared withFailedDownload helper, Binary Resolution group
- Remove flaky lock/progress file assertions from concurrent tests
Copy file name to clipboardExpand all lines: package.json
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -62,7 +62,7 @@
62
62
"default": ""
63
63
},
64
64
"coder.binaryDestination": {
65
-
"markdownDescription": "The path to the Coder CLI binary or the directory containing it. When set to a file path (e.g., `/usr/bin/coder`), the extension uses it directly without downloading. When set to a directory, the extension looks for the CLI inside it (downloading if enabled). Defaults to the value of `CODER_BINARY_DESTINATION` if not set, otherwise the extension's global storage directory.",
65
+
"markdownDescription": "The path to the Coder CLI binary or the directory containing it. When set to a file path (e.g., `/usr/bin/coder`), the extension checks its version and downloads a replacement if it does not match the server (and downloads are enabled). When set to a directory, the extension looks for the CLI inside it (downloading if enabled). Defaults to the value of `CODER_BINARY_DESTINATION` if not set, otherwise the extension's global storage directory.",
0 commit comments