@vnejs/monorepo 0.0.8 → 0.2.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vnejs/monorepo",
3
- "version": "0.0.8",
3
+ "version": "0.2.0",
4
4
  "description": "Monorepo tooling for @vnejs",
5
5
  "main": "src/index.js",
6
6
  "bin": {
@@ -8,16 +8,16 @@
8
8
  },
9
9
  "scripts": {
10
10
  "test": "echo \"Error: no test specified\" && exit 1",
11
- "publish:major": "npx @vnejs/monorepo publish major --access public",
12
- "publish:minor": "npx @vnejs/monorepo publish minor --access public",
13
- "publish:patch": "npx @vnejs/monorepo publish patch --access public"
11
+ "publish:major": "npm version major && npm publish --access public",
12
+ "publish:minor": "npm version minor && npm publish --access public",
13
+ "publish:patch": "npm version patch && npm publish --access public"
14
14
  },
15
15
  "author": "",
16
16
  "license": "ISC",
17
17
  "dependencies": {
18
18
  "commander": "~15.0.0",
19
19
  "happy-dom": "~20.10.6",
20
- "typescript": "6.0.3",
20
+ "typescript": "7.0.2",
21
21
  "vitest": "~4.1.9"
22
22
  }
23
23
  }
package/src/bump/index.js CHANGED
@@ -133,6 +133,8 @@ module.exports = async (version, options = {}) => {
133
133
 
134
134
  console.log(`\n=== Phase 2: sync-deps --all (${packages.length} packages) ===`);
135
135
 
136
+ if (!dryRun) await confirm("Continue? [y/N] ");
137
+
136
138
  syncDeps({
137
139
  cwd: options.cwd,
138
140
  all: true,
@@ -145,6 +147,8 @@ module.exports = async (version, options = {}) => {
145
147
  if (phases.includes("patch")) {
146
148
  console.log(`\n=== Phase 3: publish:changed:patch ===`);
147
149
 
150
+ if (!dryRun) await confirm("Continue? [y/N] ");
151
+
148
152
  await runChanged({
149
153
  script: "publish:patch",
150
154
  ref: options.ref ?? "HEAD",
@@ -16,6 +16,11 @@ module.exports = (options = {}) => {
16
16
  execSync("rm -rf dist", { cwd: pkgDir, stdio: "inherit" });
17
17
  }
18
18
 
19
- const tsc = require.resolve("typescript/bin/tsc");
19
+ // TS 7 no longer exports `typescript/bin/tsc`; resolve via package.json `bin`.
20
+ const typescriptPkgPath = require.resolve("typescript/package.json");
21
+ const typescriptPkg = require(typescriptPkgPath);
22
+ const tscRel =
23
+ typeof typescriptPkg.bin === "string" ? typescriptPkg.bin : typescriptPkg.bin.tsc;
24
+ const tsc = path.resolve(path.dirname(typescriptPkgPath), tscRel);
20
25
  execSync(`node "${tsc}" -p "${config}"`, { cwd: pkgDir, stdio: "inherit" });
21
26
  };
package/src/test/index.js CHANGED
@@ -11,6 +11,6 @@ module.exports = (options = {}) => {
11
11
  process.exit(1);
12
12
  }
13
13
 
14
- const vitest = require.resolve("vitest/vitest.mjs");
14
+ const vitest = path.join(path.dirname(require.resolve("vitest/package.json")), "vitest.mjs");
15
15
  execSync(`node "${vitest}" run`, { cwd: pkgDir, stdio: "inherit" });
16
16
  };
@@ -2,7 +2,7 @@ const readPackageJson = require("./read-package-json");
2
2
  const matchVersion = require("./match-version");
3
3
  const isStubTestScript = require("./is-stub-test-script");
4
4
 
5
- const DEFAULT_EXCLUDED_DIRS = ["cli"];
5
+ const DEFAULT_EXCLUDED_DIRS = [];
6
6
 
7
7
  const isExcludedDir = (dir, excludedDirs) =>
8
8
  excludedDirs.some((excluded) => dir === excluded || dir.startsWith(`${excluded}/`));