mirror of
https://github.com/tauri-apps/tauri-action.git
synced 2026-01-31 00:35:20 +01:00
feat: add _setup as alternative to -setup
This commit is contained in:
@@ -156,9 +156,10 @@ These inputs allow you to modify the GitHub release.
|
||||
- If you provide a `tagName` to an existing release, `releaseDraft` must be set to `true` if the existing release is a draft.
|
||||
- If you only want to build the app without having the action upload any assets, for example if you want to only use [`actions/upload-artifact`](https://github.com/actions/upload-artifact), simply omit `tagName`, `releaseName` and `releaseId`.
|
||||
- Only enable `uploadPlainBinary` if you are sure what you're doing since Tauri doesn't officially support a portable mode, especially on platforms other than Windows where standalone binaries for GUI applications basically do not exist.
|
||||
- `assetNamePattern` offers a few variables that will be replaced automatically if encapsulated in `[]`. Currently available variables are: `[name]`, `[version]`, `[platform]`, `[arch]`, `[mode]`, `[setup]`, `[ext]`.
|
||||
- `[mode]`: `debug` or `release`, depending on `includeDebug` and `includeRelease`.
|
||||
- `assetNamePattern` offers a few variables that will be replaced automatically if encapsulated in `[]`. Currently available variables are: `[name]`, `[version]`, `[platform]`, `[arch]`, `[mode]`, `[setup]`, `[_setup]`, `[ext]`.
|
||||
- `[mode]` will be replaced with `debug` or `release`, depending on `includeDebug` and `includeRelease`.
|
||||
- `[setup]` will be replaced with `-setup` which can be used to differenciate between the NSIS installer and the binary from `uploadPlainBinary`. For all other bundle types it will be an empty string.
|
||||
- `[_setup]` behaves like `[setup]` but with `_setup` instead of `-setup`.
|
||||
|
||||
## Partners
|
||||
|
||||
|
||||
3
dist/index.js
vendored
3
dist/index.js
vendored
@@ -53194,7 +53194,7 @@ function getAssetName(asset, pattern) {
|
||||
if (asset.name === 'latest.json') {
|
||||
return 'latest.json';
|
||||
}
|
||||
if (pattern && asset.name !== 'binary') {
|
||||
if (pattern) {
|
||||
return renderNamePattern(pattern, asset);
|
||||
}
|
||||
else {
|
||||
@@ -53226,6 +53226,7 @@ function createArtifact({ path, name, debug, platform, arch, bundle, version, })
|
||||
ext,
|
||||
version,
|
||||
setup: bundle == 'nsis' ? '-setup' : '',
|
||||
_setup: bundle == 'nsis' ? '_setup' : '',
|
||||
};
|
||||
}
|
||||
function getPackageJson(root) {
|
||||
|
||||
1
src/types.d.ts
vendored
1
src/types.d.ts
vendored
@@ -26,6 +26,7 @@ export interface Artifact {
|
||||
ext: string;
|
||||
version: string;
|
||||
setup: '-setup' | '';
|
||||
_setup: '_setup' | '';
|
||||
}
|
||||
|
||||
export interface BuildOptions {
|
||||
|
||||
@@ -92,7 +92,7 @@ export function getAssetName(asset: Artifact, pattern?: string) {
|
||||
return 'latest.json';
|
||||
}
|
||||
|
||||
if (pattern && asset.name !== 'binary') {
|
||||
if (pattern) {
|
||||
return renderNamePattern(
|
||||
pattern,
|
||||
asset as unknown as Record<string, string>,
|
||||
@@ -147,6 +147,7 @@ export function createArtifact({
|
||||
ext,
|
||||
version,
|
||||
setup: bundle == 'nsis' ? '-setup' : '',
|
||||
_setup: bundle == 'nsis' ? '_setup' : '',
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user