rigjs 3.0.26 → 3.0.30

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/lib/tag/index.ts CHANGED
@@ -51,6 +51,26 @@ const load = async () => {
51
51
  print.error(`create tag failed:${e.message}`);
52
52
  process.exit(1)
53
53
  }
54
+ }else if (pkgJson&&pkgJson.rig_tag_template){
55
+ let tagStr = `${pkgJson.rig_tag_template}`;
56
+
57
+ try{
58
+ const fields = pkgJson.tag_template.match(/(?<={)[^{}]+(?=})/g)
59
+ fields.forEach((field: string) => {
60
+ const value = pkgJson[field];
61
+ if (value) {
62
+ tagStr = tagStr.replace(`{${field}}`, value)
63
+ } else {
64
+ print.error(`field:${field} not found in package.json`);
65
+ process.exit(1)
66
+ }
67
+ });
68
+ shell.exec(`git tag ${tagStr}`);
69
+ print.succeed(`tag:${tagStr} created.`);
70
+ }catch(e:any){
71
+ print.error(`create tag failed:${e.message}`);
72
+ process.exit(1)
73
+ }
54
74
  }else{
55
75
  shell.exec(`git tag ${version}`);
56
76
  print.succeed(`tag:${version} created.`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rigjs",
3
- "version": "3.0.26",
3
+ "version": "3.0.30",
4
4
  "description": "A multi-repos dev tool based on yarn and git.Rigjs is intended to be the simplest way to develop,share and deliver codes between different developers or different projects.",
5
5
  "keywords": [
6
6
  "modular",
@@ -13,7 +13,10 @@
13
13
  "workspaces"
14
14
  ],
15
15
  "main": "index.js",
16
- "repository": "https://github.com/FlashHand/rig",
16
+ "repository":{
17
+ "type": "git",
18
+ "url": "https://github.com/FlashHand/rig"
19
+ },
17
20
  "author": "ralwayne",
18
21
  "license": "MIT",
19
22
  "bin": {