Skip to content

feat(init): validation to make sure config directory is inside cwd #4876

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

hyperz111
Copy link

@hyperz111 hyperz111 commented Aug 2, 2025

Description

Add validation to vitepress init when you try to place the config directory outside the CWD.

┌  Welcome to VitePress!
│
◆  Where should VitePress initialize the config?
│  ../foo█
└
┌  Welcome to VitePress!
│
▲  Where should VitePress initialize the config?
│  ../foo█
└  Please init your config inside this directory.

Absolute Path:

┌  Welcome to VitePress!
│
◆  Where should VitePress initialize the config?
│  /█
└
┌  Welcome to VitePress!
│
▲  Where should VitePress initialize the config?
│  /█
└  Please init your config inside this directory.

Linked Issues

N/A

Additional Context

N/A


Tip

The author of this PR can publish a preview release by commenting /publish below.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants