support portable for windows

This commit is contained in:
pompurin404 2024-08-14 16:38:40 +08:00
parent 7dfaceee05
commit f596888e12
No known key found for this signature in database
2 changed files with 11 additions and 5 deletions

View File

@ -49,14 +49,17 @@ jobs:
uses: actions/upload-artifact@v4
with:
name: Windows ${{ matrix.arch }}
path: dist/*.exe
path: |
dist/*setup.exe
dist/*portable.7z
if-no-files-found: error
- name: Publish Release
if: startsWith(github.ref, 'refs/tags/v')
uses: softprops/action-gh-release@v2
with:
files: |
dist/*.exe
dist/*setup.exe
dist/*portable.7z
dist/latest.yml
token: ${{ secrets.GITHUB_TOKEN }}

View File

@ -25,11 +25,14 @@ protocols:
- 'clash'
- 'mihomo'
win:
target: nsis
target:
- nsis
- 7z
artifactName: ${name}-windows-${version}-${arch}-portable.${ext}
requestedExecutionLevel: requireAdministrator
executableName: mihomo-party
artifactName: ${name}-windows-${version}-${arch}-setup.${ext}
nsis:
artifactName: ${name}-windows-${version}-${arch}-setup.${ext}
shortcutName: ${productName}
uninstallDisplayName: ${productName}
deleteAppDataOnUninstall: true
@ -59,6 +62,6 @@ linux:
category: Utility
artifactName: ${name}-linux-${version}-${arch}.${ext}
deb:
afterInstall: "build/linux/deb/postinst"
afterInstall: 'build/linux/deb/postinst'
npmRebuild: true
publish: []