mirror of https://github.com/coder/coder.git
fix: replace underscores with hyphens in slim binary name (#2509)
This commit is contained in:
parent
8d6faa3c1a
commit
97348b1c9d
|
@ -83,7 +83,12 @@ dest_dir="$(realpath "$dest_dir")"
|
|||
# Copy the binaries to the site directory.
|
||||
cd "$(dirname "$output_path")"
|
||||
for f in ./coder-slim_*; do
|
||||
f="${f#./}"
|
||||
dest="$dest_dir/${f//-slim_$version/}"
|
||||
# Remove ./ prefix
|
||||
name="${f#./}"
|
||||
# Remove "-slim_$version"
|
||||
truncated="${name//-slim_$version/}"
|
||||
# Replace underscores with hyphens
|
||||
hyphenated="${truncated//_/-}"
|
||||
dest="$dest_dir/$hyphenated"
|
||||
cp "$f" "$dest"
|
||||
done
|
||||
|
|
Loading…
Reference in New Issue