gitshu-cli v1.0.1
gitbook-cli
The GitBook command line interface.
Install this globally and you'll have access to the gitbook command anywhere on your system.
$ npm install -g gitbook-cliNote: The job of the gitbook command is to load and run the version of GitBook you have specified in your book (or the latest one), irrespective of its version. The GitBook CLI only support versions >=2.0.0 of GitBook.
How to install it?
$ npm install -g gitbook-cliHow to use it?
Build and Serve
Build a book in the curent directory using:
$ gitbook buildBuild a book in another directory:
$ gitbook build ./other_folderBuild and serve the book:
$ gitbook serve ./List all available commands using:
$ gitbook helpSpecify a specific version
By default, GitBook CLI will read the gitbook version to use from the book configuration, but you can force a specific version using --gitbook option:
$ gitbook build ./mybook --gitbook=2.0.1and list available commands in this version using:
$ gitbook help --gitbook=2.0.1Manage versions
List installed versions:
$ gitbook versionsList available versions:
$ gitbook versions:availableInstall a specific version:
$ gitbook versions:install 2.1.0
# or a pre-release
$ gitbook versions:install betaUpdate to the latest version
$ gitbook versions:updateUninstall a specific version
$ gitbook versions:uninstall 2.0.1Use a local folder as a GitBook version (for developement)
$ gitbook versions:link ./mygitbook10 years ago
