chore: fix release ci (#244)
This commit is contained in:
parent
10204c723f
commit
11a52f29c4
1 changed files with 9 additions and 10 deletions
19
.github/workflows/release.yaml
vendored
19
.github/workflows/release.yaml
vendored
|
@ -130,8 +130,7 @@ jobs:
|
||||||
set -euxo pipefail
|
set -euxo pipefail
|
||||||
|
|
||||||
bin=${GITHUB_REPOSITORY##*/}
|
bin=${GITHUB_REPOSITORY##*/}
|
||||||
src=`pwd`
|
dist_dir=`pwd`/dist
|
||||||
dist=$src/dist
|
|
||||||
name=$bin-$version-$target
|
name=$bin-$version-$target
|
||||||
executable=target/$target/release/$bin
|
executable=target/$target/release/$bin
|
||||||
|
|
||||||
|
@ -139,18 +138,18 @@ jobs:
|
||||||
executable=$executable.exe
|
executable=$executable.exe
|
||||||
fi
|
fi
|
||||||
|
|
||||||
mkdir $dist
|
mkdir $dist_dir
|
||||||
cp $executable $dist
|
cp $executable $dist_dir
|
||||||
cd $dist
|
cd $dist_dir
|
||||||
|
|
||||||
if [[ "$RUNNER_OS" == "Windows" ]]; then
|
if [[ "$RUNNER_OS" == "Windows" ]]; then
|
||||||
archive=$dist/$name.zip
|
archive=$dist_dir/$name.zip
|
||||||
7z a $archive *
|
7z a $archive *
|
||||||
echo "archive=$archive" >> $GITHUB_OUTPUT
|
echo "archive=dist/$name.zip" >> $GITHUB_OUTPUT
|
||||||
else
|
else
|
||||||
archive=$dist/$name.tar.gz
|
archive=$dist_dir/$name.tar.gz
|
||||||
tar czf $archive *
|
tar -czf $archive *
|
||||||
echo "archive=$archive" >> $GITHUB_OUTPUT
|
echo "archive=dist/$name.tar.gz" >> $GITHUB_OUTPUT
|
||||||
fi
|
fi
|
||||||
|
|
||||||
- name: Publish Archive
|
- name: Publish Archive
|
||||||
|
|
Loading…
Reference in a new issue