1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100
| https://blog.csdn.net/weixin_39637597/article/details/104456912?utm_medium=distribute.pc_relevant.none-task-blog-baidujs_title-2&spm=1001.2101.3001.4242
安装: 首先安装nodejs; 然后使用rpm安装gitbook; npm install -g gitbook-cli gitbook -V
gitbook init 生成两个初始文件;readme.md对书籍的简单介绍;summary为书籍目录结构; gitbook server:预览书目;
gitbook子目录写作: * [zilu](zilu.md) - [zilu](zilu.md) - (hrttps)
在该文件夹下生成book.json文件; 并在npm下搜索相关插件的命令(https://www.npmjs.com/),把对应的代码复制到上面即可; 复制完代码后执行, gitbook install 安装对应的插件; 最后,在进行gitbook serve即可;
https://www.npmjs.com/package/gitbook-plugin-comments-footer
gitbook-plugin-donate(打赏按钮): https://www.npmjs.com/package/gitbook-plugin-donate
gitbook-plugin-github-buttons(GitHub按钮): https://www.npmjs.com/package/gitbook-plugin-github-buttons
gitbook-plugin-edit-link(GitHub编辑按钮): https://www.npmjs.com/package/gitbook-plugin-edit-link
gitbook init //初始化目录文件 gitbook help //列出gitbook所有的命令 gitbook --help //输出gitbook-cli的帮助信息 gitbook build //生成静态网页 gitbook serve //生成静态网页并运行服务器 gitbook build --gitbook=2.0.1 //生成时指定gitbook的版本, 本地没有会先下载 gitbook ls //列出本地所有的gitbook版本 gitbook ls-remote //列出远程可用的gitbook版本 gitbook fetch 标签/版本号 //安装对应的gitbook版本 gitbook update //更新到gitbook的最新版本 gitbook uninstall 2.0.1 //卸载对应的gitbook版本 gitbook build --log=debug //指定log的级别 gitbook builid --debug //输出错误信息
https://blog.csdn.net/qq_37149933/article/details/64170653?utm_medium=distribute.pc_relevant.none-task-blog-2~default~baidujs_utm_term~default-1.searchformbaiduhighlight&spm=1001.2101.3001.4242 disqus 添加 disqus 评论插件。
* [介绍](README.md) - [next](zil.md)
{ "title": "编写gitbook电子书教程", "description": "gitbook电子书教程", "author": "sphard", "language": "zh-hans", "root": ".",
"plugins": [ "donate", "github-buttons@2.1.0", "edit-link" ],
"pluginsConfig": { "donate": { "wechat": "https://sphard.com/images/wechatpay.jpg", "alipay": "https://sphard.com/images/alipay.jpg", "title": "", "button": "打赏", "alipayText": "支付宝打赏", "wechatText": "微信打赏" }, "github-buttons": { "repo": "darrenliuwei/gitbook", "types": [ "star" ], "size": "small" }, "edit-link": { "base": "https://github.com/darrenliuwei/gitbook/edit/master", "label": "Edit This Page" } } }
https://www.jianshu.com/p/a3f2316aee77
|