-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
183 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,58 @@ | ||
name: Release | ||
|
||
on: | ||
push: | ||
tags: ['v[0-9]+.[0-9]+.[0-9]+*'] | ||
|
||
jobs: | ||
linux: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Install dependencies on Ubuntu | ||
run: sudo apt-get update && sudo apt-get install libgtk-3-dev | ||
- name: Build | ||
run: GIT_COMMIT_HASH=$(git rev-parse --short HEAD) cargo build --release | ||
- name: Gzip | ||
run: | | ||
mkdir ppd-editor | ||
mv ./target/release/ppd-editor ppd-editor/ | ||
tar -zcvf ./ppd-editor-linux-${{ github.ref_name }}.tar.gz ppd-editor | ||
mkdir ppd-viewer | ||
mv ./target/release/ppd-viewer ppd-viewer/ | ||
tar -zcvf ./ppd-viewer-linux-${{ github.ref_name }}.tar.gz ppd-viewer | ||
- name: Release | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
files: | | ||
./ppd-editor-linux-${{ github.ref_name }}.tar.gz | ||
./ppd-viewer-linux-${{ github.ref_name }}.tar.gz | ||
windows: | ||
runs-on: windows-latest | ||
defaults: | ||
run: | ||
shell: bash | ||
permissions: | ||
contents: write | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Build | ||
run: GIT_COMMIT_HASH=$(git rev-parse --short HEAD) cargo build --release | ||
- name: Install WiX | ||
run: nuget install WiX -Version 3.11.2 | ||
- name: Create msi installer | ||
run: | | ||
./WiX.*/tools/candle.exe -arch "x64" -ext WixUIExtension -ext WixUtilExtension \ | ||
-out "./ppd-editor.wixobj" "build/windows/wix/ppd-editor.wxs" | ||
./WiX.*/tools/light.exe -ext WixUIExtension -ext WixUtilExtension \ | ||
-out "./ppd-editor-windows-${{ github.ref_name }}.msi" -sice:ICE61 -sice:ICE91 \ | ||
"./ppd-editor.wixobj" | ||
- name: Release | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
files: ./ppd-editor-windows-${{ github.ref_name }}.msi |
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 |
---|---|---|
@@ -0,0 +1,21 @@ | ||
MIT License | ||
|
||
Copyright (c) 2023 Fralonra | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
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 |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{\rtf1 | ||
MIT License\ | ||
\ | ||
Copyright (c) 2023 Fralonra\ | ||
\ | ||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\ | ||
\ | ||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\ | ||
\ | ||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\ | ||
} |
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 |
---|---|---|
@@ -0,0 +1,93 @@ | ||
<?xml version="1.0" encoding="windows-1252"?> | ||
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi" xmlns:util="http://schemas.microsoft.com/wix/UtilExtension"> | ||
<Product Name="PpdEditor" | ||
Id="*" | ||
UpgradeCode="7c3c9894-b3d3-4e6a-b71a-4187e60183b3" | ||
Language="1033" | ||
Codepage="1252" | ||
Version="0.1.0" | ||
Manufacturer="Fralonra"> | ||
<Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine"/> | ||
<MajorUpgrade AllowSameVersionUpgrades="yes" DowngradeErrorMessage="A newer version of [ProductName] is already installed."/> | ||
<Icon Id="PpdEditorIcon" SourceFile=".\build\windows\ppd-editor.ico"/> | ||
<Icon Id="PpdViewerIcon" SourceFile=".\build\windows\ppd-viewer.ico"/> | ||
<WixVariable Id="WixUILicenseRtf" Value=".\build\windows\wix\license.rtf"/> | ||
<Property Id="ARPPRODUCTICON" Value="PpdEditorIcon"/> | ||
<Property Id="WIXUI_INSTALLDIR" Value="INSTALLDIR"/> | ||
<Property Id="WIXUI_EXITDIALOGOPTIONALCHECKBOXTEXT" Value="Launch PpdEditor"/> | ||
<Property Id="WixShellExecTarget" Value="[#PpdEditorExeFile]"/> | ||
<CustomAction Id="LaunchApplication" BinaryKey="WixCA" DllEntry="WixShellExec" Impersonate="yes"/> | ||
<MediaTemplate EmbedCab="yes"/> | ||
|
||
<UI> | ||
<UIRef Id="WixUI_Advanced"/> | ||
<Publish Dialog="ExitDialog" | ||
Control="Finish" | ||
Event="DoAction" | ||
Value="LaunchApplication">WIXUI_EXITDIALOGOPTIONALCHECKBOX = 1 and NOT Installed</Publish> | ||
</UI> | ||
|
||
<Directory Id="TARGETDIR" Name="SourceDir"> | ||
<Directory Id="ProgramFiles64Folder"> | ||
<Directory Id="INSTALLDIR" Name="PpdEditor"/> | ||
</Directory> | ||
<Directory Id="ProgramMenuFolder"> | ||
<Directory Id="ProgramMenu" Name="PpdEditor"/> | ||
</Directory> | ||
</Directory> | ||
|
||
<DirectoryRef Id="INSTALLDIR"> | ||
<Component Id="PpdEditorExe" Guid="*"> | ||
<File Id="PpdEditorExeFile" Source=".\target\release\ppd-editor.exe" Name="ppd-editor.exe" KeyPath="yes" Checksum="yes"/> | ||
</Component> | ||
<Component Id="PpdViewerExe" Guid="*"> | ||
<File Id="PpdViewerExeFile" Source=".\target\release\ppd-viewer.exe" Name="ppd-viewer.exe" KeyPath="yes" Checksum="yes"/> | ||
</Component> | ||
</DirectoryRef> | ||
|
||
<DirectoryRef Id="ProgramMenu"> | ||
<Component Id="Shortcut" Guid="*"> | ||
<Shortcut Id="ShortcutFile" | ||
Icon="PpdEditorIcon" | ||
Name="PpdEditor" | ||
Description="Paperdoll Editor" | ||
Target="[!PpdEditorExeFile]" | ||
WorkingDirectory="INSTALLDIR"/> | ||
<Shortcut Id="UninstallProduct" | ||
Name="Uninstall PpdEditor" | ||
Target="[SystemFolder]msiexec.exe" | ||
Arguments="/x [ProductCode]" | ||
Description="Uninstalls PpdEditor" /> | ||
<RemoveFolder Id="ProgramMenu" Directory="ProgramMenu" On="uninstall"/> | ||
<RegistryValue Root="HKCU" Key="Software\Fralonra\PpdEditor" Name="installed" Type="integer" Value="1" KeyPath="yes"/> | ||
</Component> | ||
<Component Id="ShortcutViewer" Guid="*"> | ||
<Shortcut Id="ShortcutViewerFile" | ||
Icon="PpdViewerIcon" | ||
Name="PpdViewer" | ||
Description="Paperdoll Viewer" | ||
Target="[!PpdViewerExeFile]" | ||
WorkingDirectory="INSTALLDIR"/> | ||
<RemoveFolder Id="ProgramMenu" Directory="ProgramMenu" On="uninstall"/> | ||
<RegistryValue Root="HKCU" Key="Software\Fralonra\PpdViewer" Name="installed" Type="integer" Value="1" KeyPath="yes"/> | ||
</Component> | ||
</DirectoryRef> | ||
|
||
<DirectoryRef Id="INSTALLDIR"> | ||
<Component Id="ModifyPathEnv" Guid="4e6e462c-8e9e-45b8-ab8a-8de938d4961f" KeyPath="yes"> | ||
<Environment Id="PathEnv" Value="[INSTALLDIR]" Name="PATH" Permanent="no" Part="first" Action="set" System="yes"/> | ||
</Component> | ||
</DirectoryRef> | ||
|
||
<Feature Id="PpdEditor" Title="Paperdoll Editor" Level="1"> | ||
<ComponentRef Id="PpdEditorExe"/> | ||
<ComponentRef Id="Shortcut"/> | ||
<ComponentRef Id="ModifyPathEnv"/> | ||
</Feature> | ||
|
||
<Feature Id="PpdViewer" Title="Paperdoll Viewer" Level="1"> | ||
<ComponentRef Id="PpdViewerExe"/> | ||
<ComponentRef Id="ShortcutPpdViewer"/> | ||
</Feature> | ||
</Product> | ||
</Wix> |