mirror of
https://github.com/garraflavatra/rolens.git
synced 2024-11-22 10:25:48 +01:00
Extract CI scripts to files. macOS: generate DMG
This commit is contained in:
parent
2fc7607ea7
commit
1524cdb244
30
.github/workflows/ci.yml
vendored
30
.github/workflows/ci.yml
vendored
@ -40,7 +40,11 @@ jobs:
|
||||
- name: Install Wails
|
||||
run: go install github.com/wailsapp/wails/v2/cmd/wails@latest
|
||||
|
||||
- name: Install Wails dependencies for Linux
|
||||
- name: Install build dependencies for macOS
|
||||
if: contains(matrix.platform, 'macos')
|
||||
run: brew install create-dmg
|
||||
|
||||
- name: Install build dependencies for Linux
|
||||
if: contains(matrix.platform, 'ubuntu')
|
||||
run: sudo apt-get install gtk+-3.0 webkit2gtk-4.0
|
||||
|
||||
@ -53,33 +57,15 @@ jobs:
|
||||
|
||||
- name: Cross-compile Rolens for Windows
|
||||
if: contains(matrix.platform, 'windows')
|
||||
run: |
|
||||
mkdir releases
|
||||
wails build -platform windows/amd64
|
||||
Compress-Archive -Path build\bin\* -DestinationPath releases\rolens-${{ matrix.platform }}-amd64.zip
|
||||
Remove-Item -Recurse -Confirm:$false .\build\bin
|
||||
wails build -platform windows/arm64
|
||||
Compress-Archive -Path build\bin\* -DestinationPath releases\rolens-${{ matrix.platform }}-arm64.zip
|
||||
run: ./build/windows/ci_generate.ps1 -platform "${{ matrix.platform }}"
|
||||
|
||||
- name: Cross-compile Rolens for Darwin
|
||||
if: contains(matrix.platform, 'macos')
|
||||
run: |
|
||||
mkdir releases
|
||||
wails build -platform darwin/amd64
|
||||
tar -czvf releases/rolens-${{ matrix.platform }}-amd64.tar.gz --directory build/bin Rolens.app
|
||||
rm -rf build/bin
|
||||
wails build -platform darwin/arm64
|
||||
tar -czvf releases/rolens-${{ matrix.platform }}-arm64.tar.gz --directory build/bin Rolens.app
|
||||
run: ./build/darwin/ci_generate.sh "${{ matrix.platform }}"
|
||||
|
||||
- name: Cross-compile Rolens for Linux
|
||||
if: contains(matrix.platform, 'ubuntu')
|
||||
run: |
|
||||
mkdir releases
|
||||
wails build -platform linux/amd64
|
||||
tar -czvf releases/rolens-${{ matrix.platform }}-amd64.tar.gz --directory build/bin Rolens
|
||||
# rm -rf build/bin
|
||||
# wails build -platform linux/arm64
|
||||
# tar -czvf releases/rolens-${{ matrix.platform }}-arm64.tar.gz --directory build/bin Rolens
|
||||
run: ./build/linux/ci_generate.sh "${{ matrix.platform }}"
|
||||
|
||||
- name: Upload generated binaries
|
||||
uses: actions/upload-artifact@v2
|
||||
|
BIN
Rolens.dmg
Normal file
BIN
Rolens.dmg
Normal file
Binary file not shown.
31
build/darwin/ci_generate.sh
Executable file
31
build/darwin/ci_generate.sh
Executable file
@ -0,0 +1,31 @@
|
||||
mkdir releases
|
||||
mkdir emptydir
|
||||
|
||||
# AMD/Intel
|
||||
wails build -platform darwin/amd64
|
||||
create-dmg \
|
||||
--volname Rolens \
|
||||
--window-size 155 250 \
|
||||
--volicon build/appicon.png \
|
||||
--eula LICENSE \
|
||||
--app-drop-link 750 500 \
|
||||
--icon-size 100 \
|
||||
--background build/darwin/dmg_background.png \
|
||||
--add-file Rolens.app build/bin/Rolens.app 595 250 \
|
||||
build/bin/Rolens.dmg emptydir
|
||||
tar -czvf releases/rolens-$1-amd64.tar.gz --directory build/bin Rolens.dmg
|
||||
|
||||
# ARM/AppleM1
|
||||
rm -rf build/bin
|
||||
wails build -platform darwin/arm64
|
||||
create-dmg \
|
||||
--volname Rolens \
|
||||
--window-size 155 250 \
|
||||
--volicon build/appicon.png \
|
||||
--eula LICENSE \
|
||||
--app-drop-link 750 500 \
|
||||
--icon-size 100 \
|
||||
--background build/darwin/dmg_background.png \
|
||||
--add-file Rolens.app build/bin/Rolens.app 595 250 \
|
||||
build/bin/Rolens.dmg emptydir
|
||||
tar -czvf releases/rolens-$1-arm64.tar.gz --directory build/bin Rolens.dmg
|
BIN
build/darwin/dmg_background.png
Normal file
BIN
build/darwin/dmg_background.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 20 KiB |
7
build/linux/ci_generate.sh
Executable file
7
build/linux/ci_generate.sh
Executable file
@ -0,0 +1,7 @@
|
||||
mkdir releases
|
||||
wails build -platform linux/amd64
|
||||
tar -czvf releases/rolens-${{ matrix.platform }}-amd64.tar.gz --directory build/bin Rolens
|
||||
|
||||
# rm -rf build/bin
|
||||
# wails build -platform linux/arm64
|
||||
# tar -czvf releases/rolens-${{ matrix.platform }}-arm64.tar.gz --directory build/bin Rolens
|
33
build/release_readme.txt
Normal file
33
build/release_readme.txt
Normal file
@ -0,0 +1,33 @@
|
||||
Thank you for downloading Rolens!
|
||||
=================================
|
||||
|
||||
Star the project on GitHub:
|
||||
https://github.com/garraflavatra/rolens
|
||||
|
||||
User guide
|
||||
----------
|
||||
|
||||
Rolens is designed to be as intuitive as possible. But if something is unclear
|
||||
nevertheless, you can consult the user manual:
|
||||
https://garraflavatra.github.io/rolens/
|
||||
|
||||
Questions and bugs
|
||||
------------------
|
||||
|
||||
Did you capture a bug? Please report it — thank you!
|
||||
https://github.com/garraflavatra/rolens/issues/new?assignees=garraflavatra&labels=bug&projects=&template=bug.yml
|
||||
|
||||
|
||||
Would you like to see a new feature? You can request it:
|
||||
https://github.com/garraflavatra/rolens/issues/new?assignees=garraflavatra&labels=enhancement&projects=&template=feature.yml
|
||||
|
||||
Do you have a question? Ask questions on the discussion board:
|
||||
https://github.com/garraflavatra/rolens/discussions/new?category=questions
|
||||
|
||||
Feel free to contact me if you have questions! Send an e-mail to romein@vburen.nl
|
||||
|
||||
Author and license
|
||||
------------------
|
||||
|
||||
© Romein van Buren 2023. The source code and compiled binaries are released
|
||||
under the GNU GPLv3 license — see LICENSE for the full license text.
|
9
build/windows/ci_generate.ps1
Executable file
9
build/windows/ci_generate.ps1
Executable file
@ -0,0 +1,9 @@
|
||||
param([string]$platform)
|
||||
|
||||
mkdir releases
|
||||
wails build -platform windows/amd64
|
||||
Compress-Archive -Path build\bin\* -DestinationPath releases\rolens-$platform-amd64.zip
|
||||
|
||||
Remove-Item -Recurse -Confirm:$false .\build\bin
|
||||
wails build -platform windows/arm64
|
||||
Compress-Archive -Path build\bin\* -DestinationPath releases\rolens-$platform-arm64.zip
|
Loading…
Reference in New Issue
Block a user