Files
payload/packages
Jessica Rynkar e5b28c98dc fix(cpa): overwrites existing env variables (#10636)
### What?
Using `create-payload-app` to initialize Payload in an existing Next.js
app **that does not already have Payload installed** overwrites any
existing data in the `.env` and `.env.example` files.

The desired behavior is for Payload variables to get added with no
client data lost.

### How?
Updates `manageEnvFiles` to check for existing `.env / .env.example`
file and appends or creates as necessary.

Adds tests to
`packages/create-payload-app/src/lib/create-project.spec.ts`.

#### Fixes https://github.com/payloadcms/payload/issues/10355
2025-05-01 16:03:07 +00:00
..
2025-04-30 14:52:46 -04:00
2025-04-30 14:52:46 -04:00
2025-04-30 14:52:46 -04:00
2025-04-30 14:52:46 -04:00
2025-04-30 14:52:46 -04:00