withastro / astro

The web framework for content-driven websites. ⭐️ Star to support our work!
https://astro.build
Other
45.58k stars 2.39k forks source link

.astro created with --outDir #10969

Closed cdtut closed 4 months ago

cdtut commented 4 months ago

Astro Info

Astro                    v4.7.1

If this issue only occurs in one browser, which browser is a problem?

No response

Describe the Bug

When pnpm run build fails the effect is different with --outDir astrobuild. It creates .astro under project with temporary files. If error in index.astro is fixed and run command again then .astro is deleted. But it is not created without --outDir.

What's the expected result?

--outDir should build temporary files at same place like pnpm run build and not create .astro.

Link to Minimal Reproducible Example

https://stackblitz.com/edit/github-iqja2n

Participation

matthewp commented 4 months ago

--outDir is where your built site is written to. It does not control .astro which is not currently configurable.

cdtut commented 4 months ago

@matthewp Why .astro is only used with --outDir?