Skip to content

Commit

Permalink
Merge pull request #48 from MuhammedKalkan/revert-46-revert-45-linux-…
Browse files Browse the repository at this point in the history
…amd64

"Build arm64 on linux"
  • Loading branch information
MuhammedKalkan authored Oct 1, 2022
2 parents 92e8ea6 + d205bb3 commit 33294e3
Showing 1 changed file with 59 additions and 47 deletions.
106 changes: 59 additions & 47 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,32 +38,43 @@ jobs:
choco install visualstudio2019buildtools visualstudio2019-workload-vctools
fi
if [ "$RUNNER_OS" == "macOS" ]; then
env ELECTRON_BUILDER_EXTRA_ARGS="--arm64 --x64 --config.dmg.sign=false" make build
for file in dist/OpenLens-${{ env.LENS_VERSION }}-latest.*.dmg; do
if [[ "$file" == *"arm64"* ]]; then
cp "$file" releasefiles/OpenLens-${{ env.LENS_VERSION }}-arm64.dmg
else
cp "$file" releasefiles/OpenLens-${{ env.LENS_VERSION }}.dmg
fi
done
for file in dist/OpenLens-${{ env.LENS_VERSION }}-latest.*.zip; do
if [[ "$file" == *"arm64"* ]]; then
cp "$file" releasefiles/OpenLens-${{ env.LENS_VERSION }}-arm64.zip
else
cp "$file" releasefiles/OpenLens-${{ env.LENS_VERSION }}.zip
fi
done
if [ "${CSC_LINK}" = "" ]; then
unset CSC_LINK
fi
if [ "${CSC_KEY_PASSWORD}" = "" ]; then
unset CSC_KEY_PASSWORD
fi
env ELECTRON_BUILDER_EXTRA_ARGS="--arm64 --x64 --config.dmg.sign=false" make build
for file in dist/OpenLens-${{ env.LENS_VERSION }}-latest.*.dmg; do
if [[ "$file" == *"arm64"* ]]; then
cp "$file" releasefiles/OpenLens-${{ env.LENS_VERSION }}-arm64.dmg
else
cp "$file" releasefiles/OpenLens-${{ env.LENS_VERSION }}.dmg
fi
done
for file in dist/OpenLens-${{ env.LENS_VERSION }}-latest.*.zip; do
if [[ "$file" == *"arm64"* ]]; then
cp "$file" releasefiles/OpenLens-${{ env.LENS_VERSION }}-arm64.zip
else
cp "$file" releasefiles/OpenLens-${{ env.LENS_VERSION }}.zip
fi
done
elif [ "$RUNNER_OS" == "Linux" ]; then
make build
cp dist/OpenLens-${{ env.LENS_VERSION }}-latest.*.x86_64.AppImage releasefiles/OpenLens-${{ env.LENS_VERSION }}.AppImage
cp dist/OpenLens-${{ env.LENS_VERSION }}-latest.*.amd64.deb releasefiles/OpenLens-${{ env.LENS_VERSION }}.deb
cp dist/OpenLens-${{ env.LENS_VERSION }}-latest.*.x86_64.rpm releasefiles/OpenLens-${{ env.LENS_VERSION }}.rpm
env ELECTRON_BUILDER_EXTRA_ARGS="--x64 --arm64" make build
cp dist/OpenLens-${{ env.LENS_VERSION }}-latest.*.x86_64.AppImage releasefiles/OpenLens-${{ env.LENS_VERSION }}.AppImage
cp dist/OpenLens-${{ env.LENS_VERSION }}-latest.*.amd64.deb releasefiles/OpenLens-${{ env.LENS_VERSION }}.deb
cp dist/OpenLens-${{ env.LENS_VERSION }}-latest.*.x86_64.rpm releasefiles/OpenLens-${{ env.LENS_VERSION }}.rpm
cp dist/OpenLens-${{ env.LENS_VERSION }}-latest.*.arm64.AppImage releasefiles/OpenLens-${{ env.LENS_VERSION }}.arm64.AppImage
cp dist/OpenLens-${{ env.LENS_VERSION }}-latest.*.arm64.deb releasefiles/OpenLens-${{ env.LENS_VERSION }}.arm64.deb
cp dist/OpenLens-${{ env.LENS_VERSION }}-latest.*.aarch64.rpm releasefiles/OpenLens-${{ env.LENS_VERSION }}.arm64.rpm
else
# Disable code sign on windows
unset CSC_LINK
unset CSC_KEY_PASSWORD
make build
cp dist/OpenLens*.exe releasefiles/OpenLens-${{ env.LENS_VERSION }}.exe
# Disable code sign on windows
unset CSC_LINK
unset CSC_KEY_PASSWORD
make build
cp dist/OpenLens*.exe releasefiles/OpenLens-${{ env.LENS_VERSION }}.exe
fi
shell: bash
working-directory: lens
Expand All @@ -73,6 +84,7 @@ jobs:
APPLEIDPASS: ${{ secrets.APPLEIDPASS }}
CSC_LINK: ${{ secrets.CSC_LINK }}
CSC_KEY_PASSWORD: ${{ secrets.CSC_KEY_PASSWORD }}

- name: Calculate SHA256 checksum
run: |
if [ "$RUNNER_OS" == "Windows" ]; then
Expand All @@ -88,38 +100,38 @@ jobs:
with:
name: OpenLens-${{ matrix.os }}
retention-days: 5
path: |
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.dmg
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}.AppImage
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}.deb
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}.rpm
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.zip
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}.exe
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.sha256
path: |
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.dmg
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.AppImage
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.deb
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.rpm
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.zip
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}.exe
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.sha256
- name: Release
uses: softprops/[email protected]
if: github.ref == 'refs/heads/main'
with:
tag_name: v${{ env.LENS_VERSION }}
files: |
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.dmg
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}.AppImage
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}.deb
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}.rpm
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.zip
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}.exe
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.sha256
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.dmg
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.AppImage
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.deb
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.rpm
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.zip
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}.exe
lens/releasefiles/OpenLens-${{ env.LENS_VERSION }}*.sha256
- name: Latest
uses: softprops/[email protected]
if: github.ref == 'refs/heads/main'
with:
tag_name: Latest
files: |
lens/dist/OpenLens*.dmg
lens/dist/OpenLens*.AppImage
lens/dist/OpenLens*.deb
lens/dist/OpenLens*.rpm
lens/dist/OpenLens*.exe
lens/dist/OpenLens*.zip
lens/dist/lates*.yml
lens/dist/OpenLens*.dmg
lens/dist/OpenLens*.AppImage
lens/dist/OpenLens*.deb
lens/dist/OpenLens*.rpm
lens/dist/OpenLens*.exe
lens/dist/OpenLens*.zip
lens/dist/lates*.yml

0 comments on commit 33294e3

Please sign in to comment.