diff options
author | falkTX <falktx@falktx.com> | 2021-07-31 14:48:50 +0100 |
---|---|---|
committer | falkTX <falktx@falktx.com> | 2021-07-31 14:48:50 +0100 |
commit | 116007cec8f2a2e790a846ad8ddb9830dc1d7323 (patch) | |
tree | ae2a3cd289001ca6bfea5a7b821bdfdd3ab0022d | |
parent | 37d048847052941e9a537b6ad8b7f865be68d7aa (diff) | |
download | jack2-116007cec8f2a2e790a846ad8ddb9830dc1d7323.tar.gz |
Allow custom version on macOS generate-pkg script
Signed-off-by: falkTX <falktx@falktx.com>
-rw-r--r-- | .github/workflows/build.yml | 16 | ||||
-rwxr-xr-x | macosx/generate-pkg.sh | 6 |
2 files changed, 13 insertions, 9 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 4e331648..5f9423ec 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -46,13 +46,13 @@ jobs: python ./waf configure --platform=darwin --prefix=/usr/local python ./waf build -j $(sysctl -n hw.logicalcpu) python ./waf install --destdir=$(pwd)/destdir - - name: Generate macOS package - shell: bash - run: | - ./macosx/generate-pkg.sh $(pwd)/destdir - name: Set sha8 id: slug run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)" + - name: Generate macOS package + shell: bash + run: | + ./macosx/generate-pkg.sh $(pwd)/destdir ${{ github.event.pull_request.number || steps.slug.outputs.sha8 }} - uses: actions/upload-artifact@v2 with: name: jack2-macOS-intel-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }} @@ -103,13 +103,13 @@ jobs: #install_name_tool -change "${PAWPAW_PREFIX}/jack2/lib/libjack.0.dylib" "/usr/local/lib/libjack.0.dylib" "${f}" #install_name_tool -change "${PAWPAW_PREFIX}/jack2/lib/libjacknet.0.dylib" "/usr/local/lib/libjacknet.0.dylib" "${f}" #install_name_tool -change "${PAWPAW_PREFIX}/jack2/lib/libjackserver.0.dylib" "/usr/local/lib/libjackserver.0.dylib" "${f}" - - name: Generate macOS package - shell: bash - run: | - ./macosx/generate-pkg.sh $(pwd)/destdir - name: Set sha8 id: slug run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)" + - name: Generate macOS package + shell: bash + run: | + ./macosx/generate-pkg.sh $(pwd)/destdir ${{ github.event.pull_request.number || steps.slug.outputs.sha8 }} - uses: actions/upload-artifact@v2 with: name: jack2-macOS-universal-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }} diff --git a/macosx/generate-pkg.sh b/macosx/generate-pkg.sh index a64a5ea0..79647cd2 100755 --- a/macosx/generate-pkg.sh +++ b/macosx/generate-pkg.sh @@ -15,7 +15,11 @@ fi # --------------------------------------------------------------------------------------------------------------------- -VERSION=$(cat ../wscript | awk 'sub("VERSION=","")' | tr -d "'") +if [ -n "${2}" ]; then + VERSION="${2}" +else + VERSION=$(cat ../wscript | awk 'sub("VERSION=","")' | tr -d "'") +fi rm -f jack2-osx-root.pkg rm -f jack2-osx-${VERSION}.pkg |