windmill-cli 1.725.0 → 1.726.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/esm/main.js +42 -2
  2. package/package.json +1 -1
package/esm/main.js CHANGED
@@ -16772,7 +16772,7 @@ var init_OpenAPI = __esm(() => {
16772
16772
  PASSWORD: undefined,
16773
16773
  TOKEN: getEnv3("WM_TOKEN"),
16774
16774
  USERNAME: undefined,
16775
- VERSION: "1.725.0",
16775
+ VERSION: "1.726.0",
16776
16776
  WITH_CREDENTIALS: true,
16777
16777
  interceptors: {
16778
16778
  request: new Interceptors,
@@ -25347,7 +25347,7 @@ var init_auth = __esm(async () => {
25347
25347
  });
25348
25348
 
25349
25349
  // src/core/constants.ts
25350
- var WM_FORK_PREFIX = "wm-fork", VERSION = "1.725.0";
25350
+ var WM_FORK_PREFIX = "wm-fork", VERSION = "1.726.0";
25351
25351
 
25352
25352
  // src/utils/git.ts
25353
25353
  var exports_git = {};
@@ -65974,6 +65974,7 @@ __export(exports_sync, {
65974
65974
  readDirRecursiveWithIgnore: () => readDirRecursiveWithIgnore2,
65975
65975
  push: () => push4,
65976
65976
  pull: () => pull,
65977
+ preservePendingScriptLocks: () => preservePendingScriptLocks,
65977
65978
  isWhitelisted: () => isWhitelisted,
65978
65979
  isCaseInsensitiveFilesystem: () => isCaseInsensitiveFilesystem,
65979
65980
  ignoreF: () => ignoreF,
@@ -67301,6 +67302,42 @@ async function isCaseInsensitiveFilesystem(dir) {
67301
67302
  _caseInsensitiveFsCache = result;
67302
67303
  return result;
67303
67304
  }
67305
+ function preservePendingScriptLocks(remote, local) {
67306
+ const modMeta = getModuleFolderSuffix() + "/script";
67307
+ for (const metaKey of Object.keys(remote)) {
67308
+ const isYaml = metaKey.endsWith(".script.yaml") || metaKey.endsWith(modMeta + ".yaml");
67309
+ const isJson = metaKey.endsWith(".script.json") || metaKey.endsWith(modMeta + ".json");
67310
+ if (!isYaml && !isJson)
67311
+ continue;
67312
+ const localMeta = local[metaKey];
67313
+ if (localMeta === undefined)
67314
+ continue;
67315
+ let remoteParsed;
67316
+ let localParsed;
67317
+ try {
67318
+ remoteParsed = isYaml ? yamlParseContent(metaKey, remote[metaKey]) : JSON.parse(remote[metaKey]);
67319
+ localParsed = isYaml ? yamlParseContent(metaKey, localMeta) : JSON.parse(localMeta);
67320
+ } catch {
67321
+ continue;
67322
+ }
67323
+ if (typeof remoteParsed !== "object" || remoteParsed === null)
67324
+ continue;
67325
+ if (typeof localParsed !== "object" || localParsed === null)
67326
+ continue;
67327
+ const remoteLock = remoteParsed["lock"];
67328
+ if (remoteLock !== undefined && remoteLock !== null)
67329
+ continue;
67330
+ const localLock = localParsed["lock"];
67331
+ if (typeof localLock !== "string" || !localLock.startsWith("!inline "))
67332
+ continue;
67333
+ const lockKey = localLock.slice("!inline ".length);
67334
+ if (local[lockKey] === undefined)
67335
+ continue;
67336
+ remoteParsed["lock"] = localLock;
67337
+ remote[metaKey] = isYaml ? import_yaml11.stringify(remoteParsed, yamlOptions) : JSON.stringify(remoteParsed, null, 2);
67338
+ remote[lockKey] = local[lockKey];
67339
+ }
67340
+ }
67304
67341
  async function compareDynFSElement(els1, els2, ignore, json, skips, ignoreMetadataDeletion, codebases, ignoreCodebaseChanges, specificItems, branchOverride, isEls1Remote, caseInsensitiveFs) {
67305
67342
  let [m1, m2] = els2 ? await Promise.all([
67306
67343
  elementsToMap(els1, ignore, json, skips, specificItems, branchOverride, isEls1Remote),
@@ -67324,6 +67361,9 @@ async function compareDynFSElement(els1, els2, ignore, json, skips, ignoreMetada
67324
67361
  }
67325
67362
  }
67326
67363
  }
67364
+ if (isEls1Remote === true) {
67365
+ preservePendingScriptLocks(m1, m2);
67366
+ }
67327
67367
  const changes = [];
67328
67368
  function parseYaml(k, v) {
67329
67369
  if (k.endsWith(".script.yaml")) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "windmill-cli",
3
- "version": "1.725.0",
3
+ "version": "1.726.0",
4
4
  "description": "CLI for Windmill",
5
5
  "license": "Apache 2.0",
6
6
  "type": "module",