create-payload-app
Advanced tools
Comparing version 3.14.1-canary.881311e to 3.14.1-canary.a85318b
@@ -13,2 +13,4 @@ import * as p from '@clack/prompts'; | ||
import { downloadTemplate } from './download-template.js'; | ||
import { generateSecret } from './generate-secret.js'; | ||
import { manageEnvFiles } from './manage-env-files.js'; | ||
const filename = fileURLToPath(import.meta.url); | ||
@@ -105,2 +107,13 @@ const dirname = path.dirname(filename); | ||
} | ||
// Call manageEnvFiles before initializing Git | ||
if (dbDetails) { | ||
await manageEnvFiles({ | ||
cliArgs, | ||
databaseType: dbDetails.type, | ||
databaseUri: dbDetails.dbUri, | ||
payloadSecret: generateSecret(), | ||
projectDir, | ||
template: 'template' in args ? args.template : undefined | ||
}); | ||
} | ||
// Remove yarn.lock file. This is only desired in Payload Cloud. | ||
@@ -107,0 +120,0 @@ const lockPath = path.resolve(projectDir, 'pnpm-lock.yaml'); |
@@ -208,3 +208,2 @@ import * as p from '@clack/prompts'; | ||
const dbDetails = await selectDb(this.args, projectName); | ||
const payloadSecret = generateSecret(); | ||
await createProject({ | ||
@@ -218,10 +217,2 @@ cliArgs: this.args, | ||
}); | ||
await manageEnvFiles({ | ||
cliArgs: this.args, | ||
databaseType: dbDetails.type, | ||
databaseUri: dbDetails.dbUri, | ||
payloadSecret, | ||
projectDir, | ||
template | ||
}); | ||
break; | ||
@@ -228,0 +219,0 @@ } |
{ | ||
"name": "create-payload-app", | ||
"version": "3.14.1-canary.881311e", | ||
"version": "3.14.1-canary.a85318b", | ||
"homepage": "https://payloadcms.com", | ||
@@ -5,0 +5,0 @@ "repository": { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
267344
2645