@take-out/scripts 0.0.68 → 0.0.70

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/package.json +3 -3
  2. package/src/up.ts +10 -5
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@take-out/scripts",
3
- "version": "0.0.68",
3
+ "version": "0.0.70",
4
4
  "type": "module",
5
5
  "main": "./src/run.ts",
6
6
  "sideEffects": false,
@@ -28,9 +28,9 @@
28
28
  "access": "public"
29
29
  },
30
30
  "dependencies": {
31
- "@take-out/helpers": "0.0.67"
31
+ "@take-out/helpers": "0.0.69"
32
32
  },
33
33
  "devDependencies": {
34
- "vxrn": "*1.4.10"
34
+ "vxrn": "1.4.10-1770207233041"
35
35
  }
36
36
  }
package/src/up.ts CHANGED
@@ -200,11 +200,16 @@ function updatePackageJsonVersions(
200
200
  if (pkg in depsObject && !depsObject[pkg].startsWith('workspace:')) {
201
201
  const newVersion = versionMap.get(pkg)
202
202
  if (newVersion) {
203
- const currentVersion = depsObject[pkg]
204
- // preserve version prefix (^, ~, >=, etc) or use exact if none
205
- const prefixMatch = currentVersion.match(/^([^\d]*)/)
206
- const prefix = prefixMatch?.[1] || ''
207
- depsObject[pkg] = `${prefix}${newVersion}`
203
+ // for tagged versions (canary, rc, etc), use exact version (no prefix)
204
+ // otherwise preserve version prefix (^, ~, >=, etc)
205
+ if (globalTag) {
206
+ depsObject[pkg] = newVersion
207
+ } else {
208
+ const currentVersion = depsObject[pkg]
209
+ const prefixMatch = currentVersion.match(/^([^\d]*)/)
210
+ const prefix = prefixMatch?.[1] || ''
211
+ depsObject[pkg] = `${prefix}${newVersion}`
212
+ }
208
213
  updatedCount++
209
214
  }
210
215
  }