@sveltepress/create 0.34.0 → 0.35.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/dist/index.cjs CHANGED
@@ -3,6 +3,7 @@
3
3
  const fs = require('node:fs');
4
4
  const path = require('node:path');
5
5
  const node_url = require('node:url');
6
+ const process = require('node:process');
6
7
  const spawn = require('cross-spawn');
7
8
  const minimist = require('minimist');
8
9
  const prompts = require('prompts');
@@ -12,14 +13,15 @@ function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'defau
12
13
 
13
14
  const fs__default = /*#__PURE__*/_interopDefaultCompat(fs);
14
15
  const path__default = /*#__PURE__*/_interopDefaultCompat(path);
16
+ const process__default = /*#__PURE__*/_interopDefaultCompat(process);
15
17
  const spawn__default = /*#__PURE__*/_interopDefaultCompat(spawn);
16
18
  const minimist__default = /*#__PURE__*/_interopDefaultCompat(minimist);
17
19
  const prompts__default = /*#__PURE__*/_interopDefaultCompat(prompts);
18
20
  const pc__default = /*#__PURE__*/_interopDefaultCompat(pc);
19
21
 
20
22
  const { yellow, blue, reset, red } = pc__default;
21
- const argv = minimist__default(process.argv.slice(2), { string: ["_"] });
22
- const cwd = process.cwd();
23
+ const argv = minimist__default(process__default.argv.slice(2), { string: ["_"] });
24
+ const cwd = process__default.cwd();
23
25
  const FRAMEWORKS = [
24
26
  {
25
27
  name: "js",
@@ -113,7 +115,7 @@ async function init() {
113
115
  else if (!fs__default.existsSync(root))
114
116
  fs__default.mkdirSync(root, { recursive: true });
115
117
  const template = language || argTemplate;
116
- const pkgInfo = pkgFromUserAgent(process.env.npm_config_user_agent);
118
+ const pkgInfo = pkgFromUserAgent(process__default.env.npm_config_user_agent);
117
119
  const pkgManager = pkgInfo ? pkgInfo.name : "npm";
118
120
  const isYarn1 = pkgManager === "yarn" && pkgInfo?.version.startsWith("1.");
119
121
  const { customCommand } = FRAMEWORKS.find((v) => v.name === template) ?? {};
@@ -129,7 +131,7 @@ async function init() {
129
131
  const { status } = spawn__default.sync(command, args, {
130
132
  stdio: "inherit"
131
133
  });
132
- process.exit(status ?? 0);
134
+ process__default.exit(status ?? 0);
133
135
  }
134
136
  console.log(`
135
137
  Scaffolding project in ${root}...`);
package/dist/index.mjs CHANGED
@@ -1,6 +1,7 @@
1
1
  import fs from 'node:fs';
2
2
  import path from 'node:path';
3
3
  import { fileURLToPath } from 'node:url';
4
+ import process from 'node:process';
4
5
  import spawn from 'cross-spawn';
5
6
  import minimist from 'minimist';
6
7
  import prompts from 'prompts';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sveltepress/create",
3
- "version": "0.34.0",
3
+ "version": "0.35.0",
4
4
  "description": "The helper for creating sveltepress projects",
5
5
  "exports": {
6
6
  ".": {
@@ -35,9 +35,9 @@
35
35
  "devDependencies": {
36
36
  "@types/cross-spawn": "^6.0.2",
37
37
  "@types/minimist": "^1.2.2",
38
- "@types/node": "^20.3.1",
38
+ "@types/node": "^20.4.2",
39
39
  "@types/prompts": "^2.4.4",
40
- "typescript": "^5.1.3",
40
+ "typescript": "^5.1.6",
41
41
  "unbuild": "^1.2.1"
42
42
  },
43
43
  "dependencies": {
@@ -8,12 +8,12 @@
8
8
  },
9
9
  "devDependencies": {
10
10
  "@sveltejs/adapter-static": "^2.0.2",
11
- "@sveltejs/kit": "^1.20.5",
12
- "@sveltepress/theme-default": "^1.15.0",
13
- "@sveltepress/vite": "^0.25.0",
14
- "@types/node": "^20.3.1",
15
- "svelte": "^4.0.0",
16
- "vite": "^4.3.9"
11
+ "@sveltejs/kit": "^1.22.3",
12
+ "@sveltepress/theme-default": "^1.17.0",
13
+ "@sveltepress/vite": "^0.26.0",
14
+ "@types/node": "^20.4.2",
15
+ "svelte": "^4.0.5",
16
+ "vite": "^4.4.3"
17
17
  },
18
18
  "type": "module",
19
19
  "license": "MIT"
@@ -8,13 +8,13 @@
8
8
  },
9
9
  "devDependencies": {
10
10
  "@sveltejs/adapter-static": "^2.0.2",
11
- "@sveltejs/kit": "^1.20.5",
12
- "@sveltepress/theme-default": "^1.15.0",
13
- "@sveltepress/vite": "^0.25.0",
14
- "@types/node": "^20.3.1",
15
- "svelte": "^4.0.0",
16
- "typescript": "^5.1.3",
17
- "vite": "^4.3.9"
11
+ "@sveltejs/kit": "^1.22.3",
12
+ "@sveltepress/theme-default": "^1.17.0",
13
+ "@sveltepress/vite": "^0.26.0",
14
+ "@types/node": "^20.4.2",
15
+ "svelte": "^4.0.5",
16
+ "typescript": "^5.1.6",
17
+ "vite": "^4.4.3"
18
18
  },
19
19
  "type": "module",
20
20
  "license": "MIT"