refactor!: rename includeUpdaterJson to uploadUpdaterJson (#1208)

This commit is contained in:
Fabian-Lars
2025-11-22 16:19:42 +01:00
committed by GitHub
parent b52116e57d
commit 25f373077a
6 changed files with 14 additions and 8 deletions

View File

@@ -0,0 +1,5 @@
---
action: major
---
**Breaking Change**: Renamed `includeUpdaterJson` to `uploadUpdaterJson` for consistency with other similar options.

View File

@@ -173,7 +173,7 @@ jobs:
# This file assume you're using the GitHub Release as your updater endpoint.
#
# default: true
includeUpdaterJson: true
uploadUpdaterJson: true
# Whether the action will use the NSIS (setup.exe) or WiX (.msi) bundles for the updater JSON if both types exist.
#

View File

@@ -24,7 +24,7 @@ inputs:
projectPath:
description: 'Path to the root of the project that will be built. It must NOT be gitignored.'
default: '.'
includeUpdaterJson:
uploadUpdaterJson:
description: 'Whether to upload a static JSON file for the updater using GitHub Releases as the CDN'
default: 'true'
updaterJsonPreferNsis:

6
dist/index.js vendored
View File

@@ -85351,7 +85351,7 @@ async function run() {
}
if (releaseId) {
await (0,_upload_release_assets__WEBPACK_IMPORTED_MODULE_6__/* .uploadAssets */ .r)(releaseId, artifacts, _inputs__WEBPACK_IMPORTED_MODULE_5__/* .retryAttempts */ .z);
if (_inputs__WEBPACK_IMPORTED_MODULE_5__/* .includeUpdaterJson */ .Sv) {
if (_inputs__WEBPACK_IMPORTED_MODULE_5__/* .shouldUploadUpdaterJson */ .Qe) {
// Once we start throwing our own errors in this function we may need some custom retry logic.
// We can't retry just the inner asset upload as that may upload an outdated latest.json file.
await (0,_utils__WEBPACK_IMPORTED_MODULE_9__/* .retry */ .L5)(() => (0,_upload_version_json__WEBPACK_IMPORTED_MODULE_7__/* .uploadVersionJSON */ .Y)(info.version, body, tagName, releaseId, artifacts, targetInfo, info.unzippedSigs),
@@ -85386,7 +85386,6 @@ __nccwpck_require__.d(__webpack_exports__, {
K4: () => (/* binding */ draft),
yK: () => (/* binding */ generateReleaseNotes),
qu: () => (/* binding */ githubBaseUrl),
Sv: () => (/* binding */ includeUpdaterJson),
m0: () => (/* binding */ isAndroid),
_o: () => (/* binding */ isDebug),
Hd: () => (/* binding */ isGitea),
@@ -85400,6 +85399,7 @@ __nccwpck_require__.d(__webpack_exports__, {
dw: () => (/* binding */ releaseAssetNamePattern),
LB: () => (/* binding */ repo),
z: () => (/* binding */ retryAttempts),
Qe: () => (/* binding */ shouldUploadUpdaterJson),
Jc: () => (/* binding */ shouldUploadWorkflowArtifacts),
PK: () => (/* binding */ tauriScript),
ZQ: () => (/* binding */ updaterJsonPreferNsis),
@@ -85466,7 +85466,7 @@ function firstString() {
const projectPath = (0,external_node_path_.resolve)(process.cwd(), core.getInput('projectPath') || process.argv[2]);
const includeUpdaterJson = core.getBooleanInput('includeUpdaterJson');
const shouldUploadUpdaterJson = core.getBooleanInput('uploadUpdaterJson');
const retryAttempts = parseInt(core.getInput('retryAttempts') || '0', 10);
const tauriScript = core.getInput('tauriScript') || undefined;
const releaseAssetNamePattern = core.getInput('releaseAssetNamePattern') || undefined;

View File

@@ -6,7 +6,7 @@ import * as core from '@actions/core';
import { buildProject } from './build';
import { getOrCreateRelease } from './create-release';
import {
includeUpdaterJson,
shouldUploadUpdaterJson,
isIOS,
parsedArgs,
retryAttempts,
@@ -127,7 +127,7 @@ async function run(): Promise<void> {
if (releaseId) {
await uploadReleaseAssets(releaseId, artifacts, retryAttempts);
if (includeUpdaterJson) {
if (shouldUploadUpdaterJson) {
// Once we start throwing our own errors in this function we may need some custom retry logic.
// We can't retry just the inner asset upload as that may upload an outdated latest.json file.
await retry(

View File

@@ -10,7 +10,8 @@ export const projectPath = resolve(
core.getInput('projectPath') || process.argv[2],
);
export const includeUpdaterJson = core.getBooleanInput('includeUpdaterJson');
export const shouldUploadUpdaterJson =
core.getBooleanInput('uploadUpdaterJson');
export const retryAttempts = parseInt(
core.getInput('retryAttempts') || '0',