escribano 0.4.1 → 0.4.2
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.
- package/package.json +1 -1
- package/scripts/create-release.mjs +12 -6
package/package.json
CHANGED
|
@@ -19,12 +19,18 @@ function getCurrentTag() {
|
|
|
19
19
|
const pkg = JSON.parse(readFileSync(join(REPO_ROOT, "package.json")));
|
|
20
20
|
const tag = `v${pkg.version}`;
|
|
21
21
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
22
|
+
// Check if tag already exists locally
|
|
23
|
+
try {
|
|
24
|
+
run(`git rev-parse ${tag}`);
|
|
25
|
+
console.log(`✅ Tag ${tag} already exists locally`);
|
|
26
|
+
return tag;
|
|
27
|
+
} catch {
|
|
28
|
+
console.log(`⚠️ No tag found, creating ${tag}...`);
|
|
29
|
+
run(`git tag ${tag}`);
|
|
30
|
+
run(`git push origin ${tag}`);
|
|
31
|
+
console.log(`✅ Created and pushed tag: ${tag}`);
|
|
32
|
+
return tag;
|
|
33
|
+
}
|
|
28
34
|
}
|
|
29
35
|
}
|
|
30
36
|
|