Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/git/24.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
如何在github子目录上托管Jekyll博客?_Git_Github_Jekyll_Blogs_Github Pages - Fatal编程技术网

如何在github子目录上托管Jekyll博客?

如何在github子目录上托管Jekyll博客?,git,github,jekyll,blogs,github-pages,Git,Github,Jekyll,Blogs,Github Pages,我想在Github上我的主repo的子目录中使用Jekyll创建一个博客。目前,我在上有一个登录页/文件夹,我想在www.jonbstrong.com/blog 上的说明仅适用于您希望在主repo中安装日志的情况。只需创建一个blog存储库并在其中发送您的Jekyll文件(gh pages分支)。然后您将能够访问www.jonbstrong.com/blog 编辑: 用户/组织存储库发布在master分支中。任何其他存储库,如username.github.io/repositoryName,都

我想在Github上我的主repo的子目录中使用Jekyll创建一个博客。目前,我在上有一个登录页/文件夹,我想在
www.jonbstrong.com/blog


上的说明仅适用于您希望在主repo中安装日志的情况。

只需创建一个
blog
存储库并在其中发送您的Jekyll文件(gh pages分支)。然后您将能够访问www.jonbstrong.com/blog

编辑: 用户/组织存储库发布在
master
分支中。任何其他存储库,如username.github.io/repositoryName,都将在
gh页面
branch中发布

git checkout -b gh-pages
git add -A
git commit -m "first commit in gh-pages branch"
git push origin gh-pages

完成。

我看不到有人在这里提出任何实际问题。你能详细说明一下你在问什么,以及你尝试了哪些不起作用的内容吗?我在问:如何在github子目录上安装一个jekyll博客?我已经创建了一个博客存储库并在那里创建了一个jekyll博客,但是我不确定如何使用页面而不是主控,我无法使用www.jonbstrong.com/blog地址访问它。下面是我使用的命令的完整列表:jekyll new myblog | cd myblog | jekyll serve | git init | git add-A | git commit-m“first commit”| git remote add origin | git push-u origin master`非常感谢您的帮助!然而,我现在看到一些非常奇怪的布局,似乎jekyll安装缺少样式或出现了问题。在
\u config.yml
中,您必须设置
baseurl:“/blog”