File tree Expand file tree Collapse file tree 1 file changed +28
-4
lines changed
Expand file tree Collapse file tree 1 file changed +28
-4
lines changed Original file line number Diff line number Diff line change @@ -168,6 +168,30 @@ echo "上传完成"
168168```
169169
170170
171+
172+ 在使用 ` gitbook-cli ` 时,可能会遇到如下问题:
173+
174+ ``` bash
175+ $ gitbook --version
176+ CLI version: 2.3.2
177+ Installing GitBook 3.2.3
178+ /Users/alphahinex/.nvm/versions/node/v12.22.12/lib/node_modules/gitbook-cli/node_modules/npm/node_modules/graceful-fs/polyfills.js:287
179+ if (cb) cb.apply(this, arguments)
180+ ^
181+
182+ TypeError: cb.apply is not a function
183+ at /Users/alphahinex/.nvm/versions/node/v12.22.12/lib/node_modules/gitbook-cli/node_modules/npm/node_modules/graceful-fs/polyfills.js:287:18
184+ at FSReqCallback.oncomplete (fs.js:169:5)
185+ ` ` `
186+
187+
188+
189+ 降低 gitbook-cli 版本解决此问题
190+
191+ ` ` ` bash
192+ npm install -g gitbook-cli@2.2.0
193+ ` ` `
194+
171195# # gitboot配置
172196
173197介绍一下gitbook中book.json的一些实用配置和插件
@@ -274,13 +298,13 @@ Gitbook默认自带有5个插件:
274298` ` `
275299
276300 code 代码添加行号& 复制按钮(可选)
277-
301+
278302 ` ` ` json
279303
280304{
281305 " plugins" : [ " code" ]
282306}
283- ```
307+ ` ` `
284308
285309如果想去掉复制按钮,在book.json的插件配置块更新:
286310
@@ -297,13 +321,13 @@ Gitbook默认自带有5个插件:
297321` ` `
298322
299323 copy-code-button 代码块复制按钮
300-
324+
301325 ` ` ` json
302326
303327{
304328 " plugins" : [" copy-code-button" ]
305329}
306- ```
330+ ` ` `
307331
308332
309333将logo插入到导航栏上方中
You can’t perform that action at this time.
0 commit comments