Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/cd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ jobs:
run: |
src="dist/github-code-search-$(echo '${{ matrix.target }}' | sed 's/^bun-//')"
[ -f "${src}.exe" ] && src="${src}.exe"
mv -v "$src" "dist/${{ matrix.artifact }}"
mv -iv "$src" "dist/${{ matrix.artifact }}"
Copy link

Copilot AI Feb 19, 2026

Choose a reason for hiding this comment

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

Using mv -i in a GitHub Actions step can block or behave unexpectedly if the destination already exists (it may prompt for confirmation, resulting in a hang or a skipped move). More importantly, for several matrix entries src already equals dist/${{ matrix.artifact }} (e.g., linux and windows), so this mv will fail with “are the same file” regardless of -i. Consider computing dest="dist/${{ matrix.artifact }}" and skipping the move when src == dest, and keep the command non-interactive (e.g., plain mv -v with a pre-check/removal or a no-clobber strategy).

Suggested change
mv -iv "$src" "dist/${{ matrix.artifact }}"
dest="dist/${{ matrix.artifact }}"
if [ "$src" != "$dest" ]; then
# Ensure we don't get blocked by interactive prompts and avoid
# "are the same file" errors when src == dest.
[ -e "$dest" ] && rm -f "$dest"
mv -v "$src" "$dest"
fi

Copilot uses AI. Check for mistakes.

- name: Upload artifact
uses: actions/upload-artifact@v6
Expand Down