Edit Mac and Linux bundle build workflows
This commit is contained in:
parent
6fdd6293ce
commit
d496564f0d
43
.github/workflows/bundle-linux.yml
vendored
Normal file
43
.github/workflows/bundle-linux.yml
vendored
Normal file
@ -0,0 +1,43 @@
|
|||||||
|
# build-linux.yml
|
||||||
|
# Reusable workflow that builds the Libation installation bundles for Linux and MacOS.
|
||||||
|
---
|
||||||
|
name: bundle-linux
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_call:
|
||||||
|
inputs:
|
||||||
|
version:
|
||||||
|
type: string
|
||||||
|
description: 'Version number'
|
||||||
|
required: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
bundle:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
os: [linux, macos]
|
||||||
|
release_name: [chardonnay]
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Download Artifact
|
||||||
|
uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
name: "Libation.${{ inputs.version }}-${{ matrix.os }}-${{ matrix.release_name }}.tar.gz"
|
||||||
|
|
||||||
|
- name: Build bundle
|
||||||
|
id: build
|
||||||
|
run: |
|
||||||
|
SCRIPT=targz2${{ matrix.os }}bundle.sh
|
||||||
|
chmod +rwx ./Scripts/${SCRIPT}
|
||||||
|
./Scripts/${SCRIPT} "Libation.${{ inputs.version }}-${{ matrix.os }}-${{ matrix.release_name }}.tar.gz" ${{ inputs.version }}
|
||||||
|
artifact=$(ls ./bundle)
|
||||||
|
echo "artifact=${artifact}" >> "${GITHUB_OUTPUT}"
|
||||||
|
|
||||||
|
- name: Publish bundle
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: ${{ steps.build.outputs.artifact }}
|
||||||
|
path: ./bundle/${{ steps.build.outputs.artifact }}
|
||||||
|
if-no-files-found: error
|
||||||
39
.github/workflows/bundle.yml
vendored
39
.github/workflows/bundle.yml
vendored
@ -1,39 +0,0 @@
|
|||||||
# bundle.yml
|
|
||||||
# Reusable workflow that builds the MacOS app bundle.
|
|
||||||
---
|
|
||||||
name: bundle
|
|
||||||
|
|
||||||
on:
|
|
||||||
workflow_call:
|
|
||||||
inputs:
|
|
||||||
version:
|
|
||||||
type: string
|
|
||||||
description: 'Version number'
|
|
||||||
required: true
|
|
||||||
|
|
||||||
env:
|
|
||||||
FILE_NAME: "Libation.${{ inputs.version }}-macos-chardonnay"
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build_bundle:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v3
|
|
||||||
|
|
||||||
- name: Download Artifact
|
|
||||||
uses: actions/download-artifact@v3
|
|
||||||
with:
|
|
||||||
name: "${{ env.FILE_NAME }}.tar.gz"
|
|
||||||
|
|
||||||
- name: Build .app bundle
|
|
||||||
id: bundle
|
|
||||||
run: |
|
|
||||||
chmod +rwx ./Scripts/targz2bundle.sh
|
|
||||||
./Scripts/targz2bundle.sh "${{ env.FILE_NAME }}.tar.gz" ${{ inputs.version }}
|
|
||||||
|
|
||||||
- name: Publish .app bundle
|
|
||||||
uses: actions/upload-artifact@v3
|
|
||||||
with:
|
|
||||||
name: "Libation.app-${{ inputs.version }}.tar.gz"
|
|
||||||
path: "Libation.app-${{ inputs.version }}.tar.gz"
|
|
||||||
if-no-files-found: error
|
|
||||||
12
.github/workflows/release.yml
vendored
12
.github/workflows/release.yml
vendored
@ -34,20 +34,14 @@ jobs:
|
|||||||
version_override: ${{ needs.prerelease.outputs.version }}
|
version_override: ${{ needs.prerelease.outputs.version }}
|
||||||
run_unit_tests: false
|
run_unit_tests: false
|
||||||
|
|
||||||
deb:
|
|
||||||
needs: [prerelease,build]
|
|
||||||
uses: ./.github/workflows/deb.yml
|
|
||||||
with:
|
|
||||||
version: ${{ needs.prerelease.outputs.version }}
|
|
||||||
|
|
||||||
bundle:
|
bundle:
|
||||||
needs: [prerelease,build]
|
needs: [prerelease,build]
|
||||||
uses: ./.github/workflows/bundle.yml
|
uses: ./.github/workflows/bundle-linux.yml
|
||||||
with:
|
with:
|
||||||
version: ${{ needs.prerelease.outputs.version }}
|
version: ${{ needs.prerelease.outputs.version }}
|
||||||
|
|
||||||
release:
|
release:
|
||||||
needs: [prerelease,build,deb,bundle]
|
needs: [prerelease,build,bundle]
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Download artifacts
|
- name: Download artifacts
|
||||||
@ -59,7 +53,7 @@ jobs:
|
|||||||
id: release
|
id: release
|
||||||
uses: softprops/action-gh-release@v1
|
uses: softprops/action-gh-release@v1
|
||||||
with:
|
with:
|
||||||
name: Libation ${{ needs.prerelease.outputs.version }}
|
name: Libation v${{ needs.prerelease.outputs.version }}
|
||||||
body: <Put a body here>
|
body: <Put a body here>
|
||||||
draft: true
|
draft: true
|
||||||
prerelease: false
|
prerelease: false
|
||||||
|
|||||||
5
Scripts/targz2deb.sh → Scripts/targz2linuxbundle.sh
Executable file → Normal file
5
Scripts/targz2deb.sh → Scripts/targz2linuxbundle.sh
Executable file → Normal file
@ -130,7 +130,10 @@ chmod +x "$FOLDER_DEBIAN/postinst"
|
|||||||
echo "Creating .deb file..."
|
echo "Creating .deb file..."
|
||||||
dpkg-deb -Zxz --build $FOLDER_MAIN
|
dpkg-deb -Zxz --build $FOLDER_MAIN
|
||||||
|
|
||||||
|
mkdir bundle
|
||||||
|
echo "moving to ./bundle/$FOLDER_MAIN.deb"
|
||||||
|
mv "$FOLDER_MAIN.deb" "./bundle/$FOLDER_MAIN.deb"
|
||||||
|
|
||||||
rm -r "$FOLDER_MAIN"
|
rm -r "$FOLDER_MAIN"
|
||||||
|
|
||||||
echo "Done!"
|
echo "Done!"
|
||||||
|
|
||||||
@ -29,7 +29,6 @@ then
|
|||||||
exit
|
exit
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# remove trailing ".tar.gz"
|
|
||||||
BUNDLE="Libation.app"
|
BUNDLE="Libation.app"
|
||||||
echo "Bundle dir: $BUNDLE"
|
echo "Bundle dir: $BUNDLE"
|
||||||
|
|
||||||
@ -76,6 +75,10 @@ for n in "${delfiles[@]}"; do rm "$BUNDLE_MACOS/$n"; done
|
|||||||
echo "Creating app bundle: $BUNDLE-$VERSION.tar.gz"
|
echo "Creating app bundle: $BUNDLE-$VERSION.tar.gz"
|
||||||
tar -czvf "$BUNDLE-$VERSION.tar.gz" "$BUNDLE"
|
tar -czvf "$BUNDLE-$VERSION.tar.gz" "$BUNDLE"
|
||||||
|
|
||||||
|
mkdir bundle
|
||||||
|
echo "moving to ./bundle/$BUNDLE-$VERSION.tar.gz"
|
||||||
|
mv "$BUNDLE-$VERSION.tar.gz" "./bundle/$BUNDLE-$VERSION.tar.gz"
|
||||||
|
|
||||||
rm -r "$BUNDLE"
|
rm -r "$BUNDLE"
|
||||||
|
|
||||||
echo "Done!"
|
echo "Done!"
|
||||||
Loading…
x
Reference in New Issue
Block a user