feat: new -setup injection for namePattern
This commit is contained in:
@@ -176,7 +176,7 @@ jobs:
|
||||
args: ${{ matrix.args }}
|
||||
updaterJsonKeepUniversal: true
|
||||
retryAttempts: 1
|
||||
assetNamePattern: '[name]x[version]x[platform]x[arch]x[mode]x[ext]'
|
||||
assetNamePattern: '[name]x[version]x[platform]x[arch]x[mode]x[setup]x[ext]'
|
||||
uploadPlainBinary: true
|
||||
|
||||
- name: Frontend-only Project
|
||||
@@ -270,7 +270,7 @@ jobs:
|
||||
args: ${{ matrix.args }}
|
||||
updaterJsonKeepUniversal: true
|
||||
retryAttempts: 1
|
||||
assetNamePattern: '[name]x[version]x[platform]x[arch]x[mode]x[ext]'
|
||||
assetNamePattern: '[name]x[version]x[platform]x[arch]x[mode]x[setup]x[ext]'
|
||||
uploadPlainBinary: true
|
||||
|
||||
- name: Frontend-only Project
|
||||
|
||||
@@ -125,7 +125,7 @@ These inputs allow you to modify the GitHub release.
|
||||
| `releaseCommitish` | false | Any branch or commit SHA the Git tag is created from, unused if the Git tag already exists. | string | SHA of current commit |
|
||||
| `owner` | false | The account owner of the repository the release will be uploaded to. Requires `GITHUB_TOKEN` in env and a `releaseCommitish` target if it doesn't match the current repo. | string | owner of the current repo |
|
||||
| `repo` | false | The name of the repository the release will be uploaded to. Requires `GITHUB_TOKEN` in env and a `releaseCommitish` target if it doesn't match the current repo. | string | name of the current repo |
|
||||
| `assetNamePattern` | false | The naming pattern to use for the uploaded assets. If not set, the names given by Tauri's CLI are kept. Currently does not affect files uploaded by `uploadPlainBinary`. | string | none |
|
||||
| `assetNamePattern` | false | The naming pattern to use for the uploaded assets. If not set, the names given by Tauri's CLI are kept. | string | none |
|
||||
| `uploadPlainBinary` | false | Whether to upload the unbundled executable binary or not. Requires Tauri v2+. To prevent issues with Tauri's [`bundle_type`](https://docs.rs/tauri-utils/latest/tauri_utils/platform/fn.bundle_type.html) value this should only be used with the `--no-bundle` flag. | bool | false |
|
||||
|
||||
## Outputs
|
||||
@@ -156,6 +156,9 @@ 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`.
|
||||
- `[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.
|
||||
|
||||
## Partners
|
||||
|
||||
|
||||
Vendored
+1
@@ -53225,6 +53225,7 @@ function createArtifact({ path, name, debug, platform, arch, bundle, version, })
|
||||
bundle,
|
||||
ext,
|
||||
version,
|
||||
setup: bundle == 'nsis' ? '-setup' : '',
|
||||
};
|
||||
}
|
||||
function getPackageJson(root) {
|
||||
|
||||
Vendored
+1
@@ -25,6 +25,7 @@ export interface Artifact {
|
||||
bundle: string;
|
||||
ext: string;
|
||||
version: string;
|
||||
setup: '-setup' | '';
|
||||
}
|
||||
|
||||
export interface BuildOptions {
|
||||
|
||||
@@ -146,6 +146,7 @@ export function createArtifact({
|
||||
bundle,
|
||||
ext,
|
||||
version,
|
||||
setup: bundle == 'nsis' ? '-setup' : '',
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user