diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml index c7bb5d3..5c83c2d 100644 --- a/.github/workflows/dotnet.yml +++ b/.github/workflows/dotnet.yml @@ -19,8 +19,8 @@ jobs: uses: actions/setup-dotnet@v2 with: dotnet-version: 6.0.x - # - name: Restore dependencies - # run: dotnet restore + - name: Restore dependencies + run: dotnet restore - name: Publish working-directory: ./src/ZonyLrcTools.Cli run: | @@ -29,6 +29,8 @@ jobs: shell: bash env: VERSION: ${{ steps.date.outputs.date }} + - name: ls + run: ls -a # - name: Upload Release # uses: ncipollo/release-action@v1 # with: diff --git a/src/ZonyLrcTools.Cli/publish.sh b/src/ZonyLrcTools.Cli/publish.sh index 892e95c..8ee75f8 100755 --- a/src/ZonyLrcTools.Cli/publish.sh +++ b/src/ZonyLrcTools.Cli/publish.sh @@ -1,21 +1,21 @@ #!/bin/bash echo "${VERSION}" -# Platforms=('win-x64' 'linux-x64' 'osx-x64') +Platforms=('win-x64' 'linux-x64' 'osx-x64') -# if ! [ -d './TempFiles' ]; -# then -# mkdir ./TempFiles -# fi +if ! [ -d './TempFiles' ]; +then + mkdir ./TempFiles +fi -# rm -rf ./TempFiles/* +rm -rf ./TempFiles/* -# for platform in "${Platforms[@]}" -# do -# dotnet publish -r "$platform" -c Release -p:PublishSingleFile=true -p:PublishTrimmed=true --self-contained true +for platform in "${Platforms[@]}" +do + dotnet publish -r "$platform" -c Release -p:PublishSingleFile=true -p:PublishTrimmed=true --self-contained true -# cd ./bin/Release/net6.0/"$platform"/publish/ || exit -# zip -r ./ZonyLrcTools_"$platform"_"${steps.date.outputs.date}".zip ./ -# cd ../../../../../ + cd ./bin/Release/net6.0/"$platform"/publish/ || exit + zip -r ./ZonyLrcTools_"$platform"_"${VERSION}".zip ./ + cd ../../../../../ -# mv ./bin/Release/net6.0/"$platform"/publish/ZonyLrcTools_"$platform"_"$Version".zip ./TempFiles -# done \ No newline at end of file + mv ./bin/Release/net6.0/"$platform"/publish/ZonyLrcTools_"$platform"_"$Version".zip ./TempFiles +done \ No newline at end of file