mirror of
https://github.com/garraflavatra/rolens.git
synced 2025-01-18 21:17:59 +00:00
CI: trying to generate .dmg (not working yet)
This commit is contained in:
parent
dc0094b27c
commit
b5bb51c869
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
@ -41,7 +41,7 @@ jobs:
|
||||
|
||||
- name: Install build dependencies for macOS
|
||||
if: contains(matrix.platform, 'macos')
|
||||
run: brew install create-dmg
|
||||
run: npm install --global appdmg
|
||||
|
||||
- name: Install build dependencies for Linux
|
||||
if: contains(matrix.platform, 'ubuntu')
|
||||
|
3
.gitignore
vendored
3
.gitignore
vendored
@ -3,6 +3,9 @@
|
||||
/build/version.txt
|
||||
/build/bin/
|
||||
/build/windows/installer/tmp/
|
||||
/build/darwin/dmg_settings.json
|
||||
|
||||
/releases
|
||||
|
||||
/frontend/node_modules/
|
||||
/frontend/dist/
|
||||
|
@ -1,6 +1,6 @@
|
||||
# Build Directory
|
||||
|
||||
The build directory is used to house all the build files and assets for your application.
|
||||
The build directory is used to house all the build files and assets for your application.
|
||||
|
||||
The structure is:
|
||||
|
||||
@ -10,10 +10,7 @@ The structure is:
|
||||
|
||||
## Mac
|
||||
|
||||
The `darwin` directory holds files specific to Mac builds.
|
||||
These may be customised and used as part of the build. To return these files to the default state, simply delete them
|
||||
and
|
||||
build with `wails build`.
|
||||
The `darwin` directory holds files specific to Mac builds. These may be customised and used as part of the build. To return these files to the default state, simply delete them and build with `wails build`.
|
||||
|
||||
The directory contains the following files:
|
||||
|
||||
@ -22,14 +19,9 @@ The directory contains the following files:
|
||||
|
||||
## Windows
|
||||
|
||||
The `windows` directory contains the manifest and rc files used when building with `wails build`.
|
||||
These may be customised for your application. To return these files to the default state, simply delete them and
|
||||
build with `wails build`.
|
||||
The `windows` directory contains the manifest and rc files used when building with `wails build`. These may be customised for your application. To return these files to the default state, simply delete them and build with `wails build`.
|
||||
|
||||
- `icon.ico` - The icon used for the application. This is used when building using `wails build`. If you wish to
|
||||
use a different icon, simply replace this file with your own. If it is missing, a new `icon.ico` file
|
||||
will be created using the `appicon.png` file in the build directory.
|
||||
- `icon.ico` - The icon used for the application. This is used when building using `wails build`. If you wish to use a different icon, simply replace this file with your own. If it is missing, a new `icon.ico` file will be created using the `appicon.png` file in the build directory.
|
||||
- `installer/*` - The files used to create the Windows installer. These are used when building using `wails build`.
|
||||
- `info.json` - Application details used for Windows builds. The data here will be used by the Windows installer,
|
||||
as well as the application itself (right click the exe -> properties -> details)
|
||||
- `wails.exe.manifest` - The main application manifest file.
|
||||
- `info.json` - Application details used for Windows builds. The data here will be used by the Windows installer, as well as the application itself (right click the exe -> properties -> details)
|
||||
- `wails.exe.manifest` - The main application manifest file.
|
||||
|
@ -1,7 +1,27 @@
|
||||
#!/bin/sh
|
||||
|
||||
# Cleanup
|
||||
rm -rf releases
|
||||
rm -rf build/bin
|
||||
mkdir releases
|
||||
mkdir emptydir
|
||||
mkdir -p build/bin
|
||||
|
||||
# Settings
|
||||
cat > build/darwin/dmg_settings.json << EOF
|
||||
{
|
||||
"title": "Rolens",
|
||||
"background": "$(pwd)/build/darwin/dmg_background.png",
|
||||
"icon-size": 100,
|
||||
"window": {
|
||||
"size": { "width": 155, "height": 250 },
|
||||
"position": { "x": 360, "y": 360 }
|
||||
},
|
||||
"contents": [
|
||||
{ "x": 750, "y": 500, "type": "link", "path": "/Applications" },
|
||||
{ "x": 595, "y": 250, "type": "file", "path": "$(pwd)/build/bin/Rolens.app" }
|
||||
]
|
||||
}
|
||||
EOF
|
||||
|
||||
# AMD/Intel
|
||||
wails build -platform darwin/amd64
|
||||
@ -15,10 +35,13 @@ wails build -platform darwin/amd64
|
||||
# --background build/darwin/dmg_background.png \
|
||||
# --add-file Rolens.app build/bin/Rolens.app 595 250 \
|
||||
# build/bin/Rolens.dmg emptydir
|
||||
# appdmg build/darwin/dmg_settings.json build/bin/Rolens.dmg
|
||||
tar -czvf releases/rolens-$1-amd64.tar.gz --directory build/bin Rolens.app
|
||||
|
||||
# Cleanup
|
||||
rm -rf build/bin/Rolens.app
|
||||
|
||||
# ARM/AppleM1
|
||||
rm -rf build/bin
|
||||
wails build -platform darwin/arm64
|
||||
# create-dmg \
|
||||
# --volname Rolens \
|
||||
@ -30,4 +53,8 @@ wails build -platform darwin/arm64
|
||||
# --background build/darwin/dmg_background.png \
|
||||
# --add-file Rolens.app build/bin/Rolens.app 595 250 \
|
||||
# build/bin/Rolens.dmg emptydir
|
||||
# appdmg build/darwin/dmg_settings.json build/bin/Rolens.dmg
|
||||
tar -czvf releases/rolens-$1-arm64.tar.gz --directory build/bin Rolens.app
|
||||
|
||||
# Cleanup
|
||||
rm -rf build/bin/Rolens.app
|
||||
|
Loading…
Reference in New Issue
Block a user