Gitbook命令行速览

Gitbook是一个命令行工具,使用方法:

本地预览

  1. $ gitbook serve ./图书名称

输出一个静态网站

  1. $ gitbook build ./repository --output=./outputFolder

查看帮助

  1. $ gitbook -h
  2. Usage: gitbook [options] [command]
  3. Commands:
  4. build [options] [source_dir] Build a gitbook from a directory
  5. serve [options] [source_dir] Build then serve a gitbook from a directory
  6. pdf [options] [source_dir] Build a gitbook as a PDF
  7. ebook [options] [source_dir] Build a gitbook as a eBook
  8. init [source_dir] Create files and folders based on contents of SUMMARY.md
  9. Options:
  10. -h, --help output usage information
  11. -V, --version output the version number