create-payload-app 0.3.19 → 0.3.20

Sign up to get free protection for your applications and to get access to all the features.
@@ -8,7 +8,7 @@
8
8
  "dev": "cross-env PAYLOAD_CONFIG_PATH=src/payload.config.ts nodemon",
9
9
  "build:payload": "cross-env PAYLOAD_CONFIG_PATH=src/payload.config.ts payload build",
10
10
  "build:server": "tsc",
11
- "build": "yarn copyfiles && yarn build:payload && yarn build:server",
11
+ "build": "{{runCommand}} copyfiles && {{runCommand}} build:payload && {{runCommand}} build:server",
12
12
  "serve": "cross-env PAYLOAD_CONFIG_PATH=dist/payload.config.js NODE_ENV=production node dist/server.js",
13
13
  "copyfiles": "copyfiles -u 1 \"src/**/*.{html,css,scss,ttf,woff,woff2,eot,svg,jpg,png}\" dist/",
14
14
  "generate:types": "cross-env PAYLOAD_CONFIG_PATH=src/payload.config.ts payload generate:types",
@@ -70,6 +70,7 @@ function writeCommonFiles(projectDir, template, packageManager) {
70
70
  packageJson = handlebars_1.default.compile(packageJsonTemplate)({
71
71
  projectName: path_1.default.basename(projectDir),
72
72
  templateName: template.name,
73
+ runCommand: packageManager === 'yarn' ? 'yarn' : 'npm run',
73
74
  });
74
75
  return [4 /*yield*/, fs_extra_1.default.writeFile(path_1.default.resolve(projectDir, 'package.json'), packageJson)
75
76
  // nodemon.json
package/package.json CHANGED
@@ -36,7 +36,7 @@
36
36
  "prompts": "^2.4.0",
37
37
  "terminal-link": "^2.1.1"
38
38
  },
39
- "version": "0.3.19",
39
+ "version": "0.3.20",
40
40
  "devDependencies": {
41
41
  "@types/command-exists": "^1.2.0",
42
42
  "@types/degit": "^2.8.3",