vitepress
vitepress copied to clipboard
vitepress v1.0.0-alpha.4 `yarn docs:build` fail
Describe the bug
- This is a new project.
-
yarn docs:dev
can start normally. -
yarn docs:build
fail.
Reproduction
This is a new project. Only one file(index.md
) is added in the docs
directory. Then yarn docs:build
fail.
Expected behavior
yarn docs:build
success.
System Info
System:
OS: Windows 10 10.0.18363
CPU: (4) x64 Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz
Memory: 7.11 GB / 15.86 GB
Binaries:
Node: 16.13.1 - D:\software\nodejs\node.EXE
Yarn: 1.22.17 - D:\software\nodejs\yarn.CMD
npm: 8.1.2 - D:\software\nodejs\npm.CMD
Browsers:
Chrome: 103.0.5060.114
Edge: Spartan (44.18362.1533.0)
Internet Explorer: 11.0.18362.1
npmPackages:
vitepress: ^1.0.0-alpha.4 => 1.0.0-alpha.4
Additional context
$ yarn docs:build
yarn run v1.22.17
$ vitepress build docs
vitepress v1.0.0-alpha.4
✓ building client + server bundles...
✓ rendering pages...
build error:
[Error: ENOTEMPTY: directory not empty, rmdir 'C:\Users\Administrator\Desktop\blog\docs\.vitepress\.temp'] {
errno: -4051,
code: 'ENOTEMPTY',
syscall: 'rmdir',
path: 'C:\\Users\\Administrator\\Desktop\\blog\\docs\\.vitepress\\.temp'
}
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Validations
- [X] Follow our Code of Conduct
- [X] Read the docs.
- [X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
---
layout: home
hero:
name: 笔记
tagline: 一份随笔
actions:
- theme: brand
text: 开始吧
link: /start/
features:
- icon: ⚡️
title: Vite, The DX that can't be beat
details: Lorem ipsum...
- icon: 🖖
title: Power of Vue meets Markdown
details: Lorem ipsum...
- icon: 🛠️
title: Simple and minimal, always
details: Lorem ipsum...
---
Try removing that .vitepress\.temp
directory manually. This won't happen on the Vite 3 branch, I'd changed deletion there to be recursive-forced.
- How to migrate from
vuepress
tovitepress
? - The writing in
vuepress
is correct, but invitepress
is incorrect , but no detailed errors are given, resulting in the unable to locate the wrong position.(Error: ENOTEMPTY: directory not empty, rmdir 'C:\Users\Administrator\Desktop\blog\docs\.vitepress\.temp'
)
pnpm add -D vitepress@npm:@brc-dd/vitepress@next
The problem has been resolved.
I want to ask about custom styles, theme related configuration. Because some of the default styles are not appropriate.
Yeah, about that, don't use that package for your site. It's meant only for testing and might break stuff without any notice.
pnpm add -D vitepress@npm:@brc-dd/vitepress@next
The problem has been resolved.
I want to ask about custom styles, theme related configuration. Because some of the default styles are not appropriate.
I can't resolve this problem by this way, did you use another solution ?
pnpm add -D vitepress@npm:@brc-dd/vitepress@next
这个问题已经解决。 我想问一下自定义样式,主题相关的配置。因为有些默认的样式不合适。
我无法通过这种方式解决此问题,您是否使用了其他解决方案?
一样的问题哦
vitepress v1.0.0-alpha.4
⠹ building client + server bundles...
(!) Some chunks are larger than 500 KiB after minification. Consider:
- Using dynamic import() to code-split the application
- Use build.rollupOptions.output.manualChunks to improve chunking: https://rollupjs.org/guide/en/#outputmanualchunks
- Adjust chunk size limit for this warning via build.chunkSizeWarningLimit.
✓ building client + server bundles...
✓ rendering pages...
build error:
[Error: ENOTEMPTY: directory not empty, rmdir 'F:\project-lmq\wetok-admin-doc\docs\.vitepress\.temp\img\Verdaccio.assets'] {
errno: -4051,
code: 'ENOTEMPTY',
syscall: 'rmdir',
path: 'F:\\project-lmq\\wetok-admin-doc\\docs\\.vitepress\\.temp\\img\\Verdaccio.assets'
}
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @ docs:build: `vitepress build docs`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @ docs:build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Administrator\AppData\Roaming\npm-cache\_logs\2022-11-30T12_39_26_367Z-debug.log