@cmflow/cli 3.3.0 → 3.4.0-alpha.1

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 (212) hide show
  1. package/.yarn/install-state.gz +0 -0
  2. package/.yarn/releases/yarn-4.18.0.cjs +1000 -0
  3. package/.yarnrc.yml +8 -1
  4. package/bin/cm-checkfeatures.ts +10 -0
  5. package/bin/cm-clean.ts +10 -0
  6. package/bin/cm-config.ts +10 -0
  7. package/bin/cm-deploy.ts +10 -0
  8. package/bin/{cm-expedit.js → cm-expedit.ts} +4 -4
  9. package/bin/cm-fetch.ts +10 -0
  10. package/bin/cm-finish.ts +10 -0
  11. package/bin/cm-jira-releases.ts +10 -0
  12. package/bin/cm-merge.ts +10 -0
  13. package/bin/cm-publish.ts +10 -0
  14. package/bin/cm-pull.ts +8 -0
  15. package/bin/cm-push.ts +10 -0
  16. package/bin/cm-rebase.ts +10 -0
  17. package/bin/{cmrelease.js → cm-release.ts} +0 -0
  18. package/bin/cm-republish.ts +10 -0
  19. package/bin/cm-start.ts +10 -0
  20. package/bin/cm.ts +40 -0
  21. package/dist/bin/cm.mjs +74985 -0
  22. package/dist/bin/cmrelease.mjs +72397 -0
  23. package/dist/cli-truncate-BmHD4ngn.mjs +152 -0
  24. package/dist/cli-truncate-CXNquMRK.mjs +152 -0
  25. package/dist/cli-truncate-DbOyuy2e.mjs +2 -0
  26. package/dist/cli-truncate-DbOyuy2e.mjs.map +1 -0
  27. package/dist/common-CwPbT3So.mjs +66 -0
  28. package/dist/common-CwPbT3So.mjs.map +1 -0
  29. package/dist/docker-clean-tags-Cd-E8IqJ.mjs +2 -0
  30. package/dist/docker-clean-tags-Cd-E8IqJ.mjs.map +1 -0
  31. package/dist/docker-publish-B0E0qYYB.mjs +2 -0
  32. package/dist/docker-publish-B0E0qYYB.mjs.map +1 -0
  33. package/dist/get-config-DoOyLztI.mjs +41 -0
  34. package/dist/get-config-DoOyLztI.mjs.map +1 -0
  35. package/dist/get-east-asian-width-Tfn8qoqd.mjs +2 -0
  36. package/dist/get-east-asian-width-Tfn8qoqd.mjs.map +1 -0
  37. package/dist/get-east-asian-width-eFfEkHwo.mjs +682 -0
  38. package/dist/log-update-B2GqeeDd.mjs +497 -0
  39. package/dist/log-update-BldA9lkm.mjs +497 -0
  40. package/dist/log-update-By8Z-mak.mjs +6 -0
  41. package/dist/log-update-By8Z-mak.mjs.map +1 -0
  42. package/dist/rolldown-runtime-B4iAMlE-.mjs +35 -0
  43. package/dist/semver-D8gwMSFO.mjs +2 -0
  44. package/dist/semver-D8gwMSFO.mjs.map +1 -0
  45. package/dist/src/index.mjs +18 -0
  46. package/dist/src/index.mjs.map +1 -0
  47. package/dist/src/semantic/core/analyze-commits.mjs +2 -0
  48. package/dist/src/semantic/core/analyze-commits.mjs.map +1 -0
  49. package/dist/src/semantic/core/conditional.mjs +2 -0
  50. package/dist/src/semantic/core/conditional.mjs.map +1 -0
  51. package/dist/src/semantic/core/exit.mjs +2 -0
  52. package/dist/src/semantic/core/exit.mjs.map +1 -0
  53. package/dist/src/semantic/core/prepare/bump-version.mjs +48 -0
  54. package/dist/src/semantic/core/prepare/bump-version.mjs.map +1 -0
  55. package/dist/src/semantic/core/prepare/commit.mjs +2 -0
  56. package/dist/src/semantic/core/prepare/commit.mjs.map +1 -0
  57. package/dist/src/semantic/core/prepare/release-info.mjs +2 -0
  58. package/dist/src/semantic/core/prepare/release-info.mjs.map +1 -0
  59. package/dist/src/semantic/core/run.mjs +2 -0
  60. package/dist/src/semantic/core/run.mjs.map +1 -0
  61. package/dist/src/semantic/core/sync-repository.mjs +2 -0
  62. package/dist/src/semantic/core/sync-repository.mjs.map +1 -0
  63. package/dist/src/semantic/core/verify-conditions.mjs +2 -0
  64. package/dist/src/semantic/core/verify-conditions.mjs.map +1 -0
  65. package/dist/src/semantic/core/verify-release.mjs +2 -0
  66. package/dist/src/semantic/core/verify-release.mjs.map +1 -0
  67. package/dist/src/semantic/docker/publish.mjs +2 -0
  68. package/dist/src/semantic/docker/publish.mjs.map +1 -0
  69. package/dist/src/semantic/docker/success.mjs +2 -0
  70. package/dist/src/semantic/docker/success.mjs.map +1 -0
  71. package/dist/strip-ansi-Aeu5cmZe.mjs +174 -0
  72. package/dist/strip-ansi-Cl0pRo-s.mjs +2 -0
  73. package/dist/strip-ansi-Cl0pRo-s.mjs.map +1 -0
  74. package/dist/wrap-ansi-BeIjar2W.mjs +2 -0
  75. package/dist/wrap-ansi-CWIezXNl.mjs +330 -0
  76. package/dist/wrap-ansi-DsMb4WnZ.mjs +9 -0
  77. package/dist/wrap-ansi-DsMb4WnZ.mjs.map +1 -0
  78. package/dist/wrap-ansi-T0rz0Urp.mjs +330 -0
  79. package/package.json +47 -38
  80. package/release.config.mjs +6 -6
  81. package/src/commands/checkfeatures.ts +39 -0
  82. package/src/commands/clean.ts +36 -0
  83. package/src/commands/config.ts +31 -0
  84. package/src/commands/deploy.ts +39 -0
  85. package/src/commands/fetch.ts +30 -0
  86. package/src/commands/finish.ts +50 -0
  87. package/src/commands/{index.js → index.ts} +1 -0
  88. package/src/commands/jira-releases.ts +97 -0
  89. package/src/commands/merge.ts +58 -0
  90. package/src/commands/prompts/{branches.js → branches.ts} +13 -5
  91. package/src/commands/pull.ts +44 -0
  92. package/src/commands/push.ts +48 -0
  93. package/src/commands/rebase.ts +56 -0
  94. package/src/commands/republish.ts +34 -0
  95. package/src/commands/start.ts +123 -0
  96. package/src/commands/tasks/{merge-branch.js → merge-branch.ts} +18 -3
  97. package/src/commands/tasks/push-branch.ts +19 -0
  98. package/src/commands/tasks/{rebase-all-branches.js → rebase-all-branches.ts} +10 -2
  99. package/src/commands/tasks/{refresh-repository.js → refresh-repository.ts} +8 -4
  100. package/src/commands/tasks/run-test.ts +28 -0
  101. package/src/commands/tasks/{update-branch.js → update-branch.ts} +15 -9
  102. package/src/commands/tasks/{update-dependencies.js → update-dependencies.ts} +4 -3
  103. package/src/common/back/directus/{directus-flow.test.js → directus-flow.test.ts} +1 -0
  104. package/src/common/back/directus/{directus-flow.js → directus-flow.ts} +10 -2
  105. package/src/common/back/http/{http-proxy.js → http-proxy.ts} +7 -1
  106. package/src/common/back/http/{http-request.spec.js → http-request.spec.ts} +8 -7
  107. package/src/common/back/http/{http-request.js → http-request.ts} +16 -19
  108. package/src/common/back/jira/{get-sorted-releases.js → get-sorted-releases.ts} +2 -2
  109. package/src/common/back/jira/{jira-releases.js → jira-releases.ts} +14 -3
  110. package/src/common/back/jira/{jira-request.js → jira-request.ts} +9 -1
  111. package/src/common/back/jira/{jira-search.js → jira-search.ts} +2 -2
  112. package/src/common/cli/{bun.test.js → bun.test.ts} +17 -10
  113. package/src/common/cli/{bun.js → bun.ts} +4 -4
  114. package/src/common/cli/cli.ts +127 -0
  115. package/src/common/cli/{docker.test.js → docker.test.ts} +22 -14
  116. package/src/common/cli/{docker.js → docker.ts} +6 -6
  117. package/src/common/cli/{git.test.js → git.test.ts} +19 -11
  118. package/src/common/cli/{git.js → git.ts} +24 -24
  119. package/src/common/cli/{lerna.test.js → lerna.test.ts} +18 -11
  120. package/src/common/cli/{lerna.js → lerna.ts} +4 -4
  121. package/src/common/cli/{npm.test.js → npm.test.ts} +17 -10
  122. package/src/common/cli/{npm.js → npm.ts} +4 -4
  123. package/src/common/cli/{pnpm.test.js → pnpm.test.ts} +17 -10
  124. package/src/common/cli/{pnpm.js → pnpm.ts} +4 -4
  125. package/src/common/cli/{yarn.test.js → yarn.test.ts} +17 -12
  126. package/src/common/cli/{yarn.js → yarn.ts} +4 -4
  127. package/src/common/configure-git-workspace.ts +39 -0
  128. package/src/common/{get-config.js → get-config.ts} +3 -1
  129. package/src/common/{get-package-json.js → get-package-json.ts} +1 -0
  130. package/src/common/{get-package-manager.js → get-package-manager.ts} +1 -0
  131. package/src/common/{get-release-config.js → get-release-config.ts} +1 -0
  132. package/src/common/{index.js → index.ts} +1 -0
  133. package/src/common/{run-command.test.js → run-command.test.ts} +1 -0
  134. package/src/common/run-command.ts +67 -0
  135. package/src/common/types.ts +26 -0
  136. package/src/common/vendor.d.ts +4 -0
  137. package/src/{index.js → index.ts} +5 -1
  138. package/src/semantic/core/{analyze-commits.js → analyze-commits.ts} +7 -3
  139. package/src/semantic/core/{conditional.js → conditional.ts} +16 -9
  140. package/src/semantic/core/{exit.js → exit.ts} +3 -2
  141. package/src/semantic/core/prepare/{bump-version.js → bump-version.ts} +11 -8
  142. package/src/semantic/core/prepare/{commit.js → commit.ts} +3 -2
  143. package/src/semantic/core/prepare/release-info.ts +6 -0
  144. package/src/semantic/core/{run.js → run.ts} +3 -2
  145. package/src/semantic/core/sync-repository.ts +55 -0
  146. package/src/semantic/core/{verify-conditions.js → verify-conditions.ts} +4 -3
  147. package/src/semantic/core/{verify-release.js → verify-release.ts} +2 -1
  148. package/src/semantic/docker/publish.ts +6 -0
  149. package/src/semantic/docker/{success.js → success.ts} +2 -1
  150. package/src/semantic/utils/{bump-packages-version.test.js → bump-packages-version.test.ts} +1 -0
  151. package/src/semantic/utils/{bump-packages-version.js → bump-packages-version.ts} +12 -11
  152. package/src/semantic/utils/{calculate-snapshot-version.test.js → calculate-snapshot-version.test.ts} +10 -8
  153. package/src/semantic/utils/calculate-snapshot-version.ts +17 -0
  154. package/src/semantic/utils/display-package-info.ts +12 -0
  155. package/src/semantic/utils/display-release-info.ts +13 -0
  156. package/src/semantic/utils/{docker-clean-tags.test.js → docker-clean-tags.test.ts} +1 -0
  157. package/src/semantic/utils/{docker-clean-tags.js → docker-clean-tags.ts} +11 -4
  158. package/src/semantic/utils/{docker-publish.test.js → docker-publish.test.ts} +1 -0
  159. package/src/semantic/utils/{docker-publish.js → docker-publish.ts} +4 -3
  160. package/src/semantic/utils/{log-section.js → log-section.ts} +5 -1
  161. package/src/semantic/utils/{transform-writer.js → transform-writer.ts} +37 -13
  162. package/tsconfig.build.json +29 -0
  163. package/tsconfig.json +8 -15
  164. package/tsdown.config.ts +63 -0
  165. package/vitest.config.mts +2 -3
  166. package/.yarn/releases/yarn-4.7.0.cjs +0 -935
  167. package/bin/checkfeatures.js +0 -13
  168. package/bin/cm-clean.js +0 -8
  169. package/bin/cm-config.js +0 -15
  170. package/bin/cm-deploy.js +0 -8
  171. package/bin/cm-fetch.js +0 -12
  172. package/bin/cm-finish.js +0 -14
  173. package/bin/cm-jira-releases.js +0 -16
  174. package/bin/cm-merge.js +0 -12
  175. package/bin/cm-publish.js +0 -15
  176. package/bin/cm-push.js +0 -15
  177. package/bin/cm-rebase.js +0 -15
  178. package/bin/cm-republish.js +0 -12
  179. package/bin/cm-start.js +0 -21
  180. package/bin/cm.js +0 -27
  181. package/bin/cmpull.js +0 -22
  182. package/src/commands/checkfeatures.js +0 -20
  183. package/src/commands/clean.js +0 -29
  184. package/src/commands/config.js +0 -23
  185. package/src/commands/deploy.js +0 -34
  186. package/src/commands/fetch.js +0 -18
  187. package/src/commands/finish.js +0 -43
  188. package/src/commands/jira-releases.js +0 -62
  189. package/src/commands/merge.js +0 -41
  190. package/src/commands/pull.js +0 -30
  191. package/src/commands/push.js +0 -23
  192. package/src/commands/rebase.js +0 -35
  193. package/src/commands/republish.js +0 -21
  194. package/src/commands/start.js +0 -109
  195. package/src/commands/tasks/push-branch.js +0 -10
  196. package/src/commands/tasks/run-test.js +0 -21
  197. package/src/common/cli/cli.js +0 -110
  198. package/src/common/configure-git-workspace.js +0 -26
  199. package/src/common/run-command.js +0 -64
  200. package/src/semantic/core/prepare/release-info.js +0 -5
  201. package/src/semantic/core/sync-repository.js +0 -52
  202. package/src/semantic/docker/publish.js +0 -5
  203. package/src/semantic/utils/calculate-snapshot-version.js +0 -15
  204. package/src/semantic/utils/display-package-info.js +0 -11
  205. package/src/semantic/utils/display-release-info.js +0 -12
  206. /package/src/commands/{release.js → release.ts} +0 -0
  207. /package/src/commands/utils/{check-install.js → check-install.ts} +0 -0
  208. /package/src/common/back/jira/{jira-request.spec.js → jira-request.spec.ts} +0 -0
  209. /package/src/common/back/jira/{jira-search.spec.js → jira-search.spec.ts} +0 -0
  210. /package/src/semantic/{define-config.js → define-config.ts} +0 -0
  211. /package/src/semantic/utils/{release-rules.js → release-rules.ts} +0 -0
  212. /package/src/workflow/{index.js → index.ts} +0 -0
package/.yarnrc.yml CHANGED
@@ -1,3 +1,10 @@
1
+ approvedGitRepositories:
2
+ - "**"
3
+
4
+ enableScripts: true
5
+
1
6
  nodeLinker: node-modules
2
7
 
3
- yarnPath: .yarn/releases/yarn-4.7.0.cjs
8
+ npmMinimalAgeGate: 0
9
+
10
+ yarnPath: .yarn/releases/yarn-4.18.0.cjs
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+ import register from "../src/commands/checkfeatures.js";
5
+
6
+ const program = new Command();
7
+
8
+ register(program);
9
+
10
+ await program.parseAsync(process.argv);
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+ import register from "../src/commands/clean.js";
5
+
6
+ const program = new Command();
7
+
8
+ register(program);
9
+
10
+ await program.parseAsync(process.argv);
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+ import register from "../src/commands/config.js";
5
+
6
+ const program = new Command();
7
+
8
+ register(program);
9
+
10
+ await program.parseAsync(process.argv);
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+ import register from "../src/commands/deploy.js";
5
+
6
+ const program = new Command();
7
+
8
+ register(program);
9
+
10
+ await program.parseAsync(process.argv);
@@ -2,15 +2,15 @@
2
2
 
3
3
  import { getConfig, getPackageManager, git } from "../src/index.js";
4
4
 
5
- async function expedit() {
5
+ async function expedit(): Promise<void> {
6
6
  await git.fetch("--all", "--prune", "--tags");
7
7
 
8
- const featureBranch = git.getBranchName();
9
- const { PACKAGE_MANAGER } = getConfig();
8
+ const featureBranch = git.getBranchName() as string;
9
+ const { PACKAGE_MANAGER } = getConfig() as { PACKAGE_MANAGER: string };
10
10
 
11
11
  getPackageManager(PACKAGE_MANAGER).newVersion("patch");
12
12
 
13
- await git.push("-u", "-f", "origin", featureBranch);
13
+ await (git.push("-u", "-f", "origin", featureBranch) as Promise<unknown>);
14
14
 
15
15
  console.log(`${featureBranch} PUBLISH DONE`);
16
16
  console.log("End publishfeat");
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+ import register from "../src/commands/fetch.js";
5
+
6
+ const program = new Command();
7
+
8
+ register(program);
9
+
10
+ await program.parseAsync(process.argv);
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+ import register from "../src/commands/finish.js";
5
+
6
+ const program = new Command();
7
+
8
+ register(program);
9
+
10
+ await program.parseAsync(process.argv);
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+ import register from "../src/commands/jira-releases.js";
5
+
6
+ const program = new Command();
7
+
8
+ register(program);
9
+
10
+ await program.parseAsync(process.argv);
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+ import register from "../src/commands/merge.js";
5
+
6
+ const program = new Command();
7
+
8
+ register(program);
9
+
10
+ await program.parseAsync(process.argv);
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+ import register from "../src/commands/push.js";
5
+
6
+ const program = new Command();
7
+
8
+ register(program);
9
+
10
+ await program.parseAsync(process.argv);
package/bin/cm-pull.ts ADDED
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+ import register from "../src/commands/pull.js";
5
+
6
+ const program = new Command();
7
+ register(program);
8
+ await program.parseAsync(process.argv);
package/bin/cm-push.ts ADDED
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+ import register from "../src/commands/push.js";
5
+
6
+ const program = new Command();
7
+
8
+ register(program);
9
+
10
+ await program.parseAsync(process.argv);
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+ import register from "../src/commands/rebase.js";
5
+
6
+ const program = new Command();
7
+
8
+ register(program);
9
+
10
+ await program.parseAsync(process.argv);
File without changes
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+ import register from "../src/commands/republish.js";
5
+
6
+ const program = new Command();
7
+
8
+ register(program);
9
+
10
+ await program.parseAsync(process.argv);
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+ import register from "../src/commands/start.js";
5
+
6
+ const program = new Command();
7
+
8
+ register(program);
9
+
10
+ await program.parseAsync(process.argv);
package/bin/cm.ts ADDED
@@ -0,0 +1,40 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { Command } from "commander";
4
+
5
+ import registerCheckfeatures from "../src/commands/checkfeatures.js";
6
+ import registerClean from "../src/commands/clean.js";
7
+ import registerConfig from "../src/commands/config.js";
8
+ import registerDeploy from "../src/commands/deploy.js";
9
+ import registerFetch from "../src/commands/fetch.js";
10
+ import registerFinish from "../src/commands/finish.js";
11
+ import registerJiraReleases from "../src/commands/jira-releases.js";
12
+ import registerMerge from "../src/commands/merge.js";
13
+ import registerPull from "../src/commands/pull.js";
14
+ import registerPush, { publish as registerPublish } from "../src/commands/push.js";
15
+ import registerRebase from "../src/commands/rebase.js";
16
+ import registerRepublish from "../src/commands/republish.js";
17
+ import registerStart from "../src/commands/start.js";
18
+ // import registerDatasource from "../src/datasource/commands/index.js";
19
+
20
+ const program = new Command();
21
+
22
+ program.version(__VERSION__);
23
+
24
+ registerCheckfeatures(program);
25
+ registerClean(program);
26
+ registerConfig(program);
27
+ registerDeploy(program);
28
+ registerFetch(program);
29
+ registerFinish(program);
30
+ registerJiraReleases(program);
31
+ registerMerge(program);
32
+ registerPull(program);
33
+ registerPush(program);
34
+ registerPublish(program);
35
+ registerRebase(program);
36
+ registerRepublish(program);
37
+ registerStart(program);
38
+ // registerDatasource(program);
39
+
40
+ await program.parseAsync(process.argv);