File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -159,6 +159,7 @@ export function scaffold({
159
159
160
160
const dir =
161
161
root === './' ? `` : ` ${ root . replace ( / ^ \. \/ / , '' ) . replace ( / [ / \\ ] $ / , '' ) } `
162
+ const gitignorePrefix = dir ? `${ dir } /.vitepress` : '.vitepress'
162
163
163
164
const pkgPath = path . resolve ( 'package.json' )
164
165
const userPkg = fs . existsSync ( pkgPath )
@@ -168,8 +169,9 @@ export function scaffold({
168
169
const tips = [ ]
169
170
if ( fs . existsSync ( '.git' ) ) {
170
171
tips . push (
171
- `Make sure to add ${ cyan ( `.vitepress/dist` ) } and ` +
172
- `${ cyan ( `.vitepress/cache` ) } to your ${ cyan ( `.gitignore` ) } file.`
172
+ `Make sure to add ${ cyan ( `${ gitignorePrefix } /dist` ) } and ` +
173
+ `${ cyan ( `${ gitignorePrefix } /cache` ) } to your ` +
174
+ `${ cyan ( `.gitignore` ) } file.`
173
175
)
174
176
}
175
177
if (
You can’t perform that action at this time.
0 commit comments