-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Try making release that includes Windows and Linux
- Loading branch information
Showing
3 changed files
with
115 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,13 +3,13 @@ name: Build App | |
on: | ||
push: | ||
branches: | ||
- master | ||
- [master, feature/LinuxCiBuild] | ||
|
||
concurrency: ci-${{ github.ref }} | ||
|
||
jobs: | ||
|
||
build-app: | ||
build-win: | ||
name: ${{ matrix.config.name }} | ||
runs-on: ${{ matrix.config.os }} | ||
strategy: | ||
|
@@ -133,21 +133,29 @@ jobs: | |
ref: bleeding-edge | ||
description: Latest successful automated build | ||
|
||
- name: Create Release | ||
uses: ncipollo/[email protected] | ||
- name: Upload Windows artifact | ||
uses: actions/upload-artifact@v4 | ||
id: artifact-windows-upload-step | ||
with: | ||
artifacts: '${{runner.temp}}\build_${{ runner.os }}_wx_app\InterSpec_app_${{ runner.os }}_WebView_latest*.zip' | ||
draft: false | ||
prerelease: true | ||
body: "An automated, and untested build of the latest code pushed to the repository. Requires Windows 10, or may work on Windows 7 with the Edge browser runtime installed." | ||
allowUpdates: true | ||
generateReleaseNotes: false | ||
name: "Development Build" | ||
removeArtifacts: true | ||
replacesArtifacts: true | ||
tag: 'bleeding-edge' | ||
commit: ${{ github.sha }} | ||
makeLatest: true | ||
name: windows-build | ||
overwrite: true | ||
path: '${{runner.temp}}\build_${{ runner.os }}_wx_app\InterSpec_app_${{ runner.os }}_WebView_latest*.zip' | ||
|
||
# - name: Create Release | ||
# uses: ncipollo/[email protected] | ||
# with: | ||
# artifacts: '${{runner.temp}}\build_${{ runner.os }}_wx_app\InterSpec_app_${{ runner.os }}_WebView_latest*.zip' | ||
# draft: false | ||
# prerelease: true | ||
# body: "An automated, and untested build of the latest code pushed to the repository. Requires Windows 10, or may work on Windows 7 with the Edge browser runtime installed." | ||
# allowUpdates: true | ||
# generateReleaseNotes: false | ||
# name: "Development Build" | ||
# removeArtifacts: true | ||
# replacesArtifacts: true | ||
# tag: 'bleeding-edge' | ||
# commit: ${{ github.sha }} | ||
# makeLatest: true | ||
|
||
|
||
- name: "Cleanup and finish" | ||
|
@@ -156,4 +164,89 @@ jobs: | |
echo "Job status is ${{ job.status }}." | ||
build-linux: | ||
runs-on: ubuntu-latest # Use the latest Ubuntu environment | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v3 | ||
with: | ||
path: ${{ github.workspace }}/InterSpec_code | ||
submodules: true # Recursively checkout submodules | ||
|
||
- name: Cache npm dependencies | ||
uses: actions/cache@v3 | ||
with: | ||
path: ${{runner.temp}}/build_linux_working_dir | ||
key: ${{ runner.os }}-build-npm-${{ hashFiles('target/electron/package.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-build-npm- | ||
- name: Cache c++ dependencies | ||
uses: actions/cache@v3 | ||
with: | ||
path: ${{runner.temp}}/build_linux_electron | ||
key: ${{ runner.os }}-build-cpp-${{ hashFiles('cmake/FetchInterSpecDeps.txt') }} | ||
restore-keys: | | ||
${{ runner.os }}-build-cpp- | ||
- name: Make build directories | ||
shell: bash | ||
working-directory: ${{runner.temp}} | ||
run: | | ||
mkdir -p build_linux_electron | ||
mkdir -p build_linux_working_dir | ||
- name: Configure and build in Docker | ||
uses: addnab/docker-run-action@v3 | ||
env: | ||
LEAFLET_KEY: ${{ secrets.LEAFLET_KEY }} | ||
with: | ||
image: quay.io/pypa/manylinux_2_28_x86_64 | ||
shell: bash | ||
options: --name manylinux-container -v ${{ github.workspace }}/InterSpec_code:/interspec -v ${{runner.temp}}/build_linux_electron/:/build_app -v ${{runner.temp}}/build_linux_working_dir:/build_working_dir -e LEAFLET_KEY=${{ secrets.LEAFLET_KEY }} | ||
run: | | ||
echo "Running Script from within docker" | ||
/interspec/target/electron/build_linux_app_from_docker.sh /interspec /build_app /build_working_dir | ||
- name: Upload Linux artifact | ||
uses: actions/upload-artifact@v4 | ||
id: artifact-linux-upload-step | ||
with: | ||
name: linux-build | ||
overwrite: true | ||
path: ${{runner.temp}}/build_linux_working_dir/InterSpec_app_Linux_Electron_latest_*.zip | ||
|
||
release: | ||
runs-on: ubuntu-latest | ||
needs: [build-linux, build-win] | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Download Build Artifacts | ||
uses: actions/download-artifact@v4 | ||
with: | ||
pattern: *-build | ||
path: ./artifacts | ||
merge-multiple: true | ||
|
||
- name: Display structure of downloaded files | ||
run: ls -R | ||
|
||
- name: Create Release | ||
id: create_release | ||
uses: softprops/action-gh-release@v2 | ||
with: | ||
fail_on_unmatched_files: true | ||
tag_name: bleeding-edge | ||
release_name: "Development Build" | ||
body: "An automated, and untested build of the latest code pushed to the repository. Requires Windows 10, or may work on Windows 7 with the Edge browser runtime installed." | ||
draft: false | ||
prerelease: true | ||
generate_release_notes: false | ||
prerelease: true | ||
make_latest: true | ||
files: ./artifacts/** | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters