fix(cli): simplify path derivation for --output flag

- Remove unused outDir variable
- Directly use opts.output or default to cwd/.env
This commit is contained in:
ZTatman 2026-04-12 18:29:51 -04:00
parent 134d5ff8c7
commit 9647f27db4

View file

@ -77,8 +77,7 @@ async function init(opts: { output?: string }) {
c.yellow("Before you start:"),
);
const outDir = opts.output ? path.dirname(opts.output) : process.cwd();
const envPath = opts.output || path.join(outDir, ".env");
const envPath = opts.output || path.join(process.cwd(), ".env");
// Check if .env file already exists
let envExists = false;