我试着弄了一个 travis,自动编译和布署一个 bookdown 项目,然而每次到最后一步就是失败:
Deploying application
Cloning into 'book-output'...
fatal: Remote branch gh-pages not found in upstream origin
Script failed with status 128
failed to deploy
出错原因是 gh-pages 不存在。这是因为,我不知道怎么对它初始化。bookdown 说明书在这一步是这样说的:
You can clone this gh-pages branch on Travis using your GitHub token, add the HTML output files from R Markdown (do not forget to add figures and CSS style files as well), and push to the remote repository.
这句话说得很简略,我看不懂:从哪里“clone this gh-pages branch”?如何 clone?
这是我的第一个 travis 项目……