Jekyll

Why is Font Awesome not working on my jekyll-built Github site?

此生再无相见时 提交于 2020-01-24 06:42:07
问题 I am using Jekyll to build my blog site, which is hosted by Github, and I am trying to incorporate font-awesome. The fa icons don't show up, and now my Github page is not updated with my latest blog post. I've tried to link the font-awesome stylesheets to my css. I ended up using {% includes font-awesome.css %} in my stylesheet.css file, and I think that works fine. In my navbar html, I've included the typical font-awesome i tag like so: <li><a href="{{ site.baseurl }}/index.html"><i class=

How to use theme from github.io site for Github Project Pages sites

六月ゝ 毕业季﹏ 提交于 2020-01-24 01:02:16
问题 I've been working on my website on and off for a couple years, learned a ton about JavaScript, CSS, HTML, Bootstrap, Jekyll, Travis-CI, and Github Pages in the process. (Long list is a major factor in why it's taken so long.) I've discovered that if I push to (or have Travis deploy to) the gh-pages branch of a repo, it actually becomes a subdomain of my website. Examples: here, here, here. This is pretty awesome, but those sub-pages end up feeling like they're not a part of the same website,

Why is the 'post' layout missing from so many themes?

那年仲夏 提交于 2020-01-23 03:35:10
问题 I used the WordPress plugin "WordPress to Jekyll Exporter" to convert my WordPress blog to a Jekyll blog. All posts had front matter that included: layout: post But all the themes I've tested other than the default minima theme apparently do not have this post layout, because I get error messages like this from the Jekyll server for every post: Build Warning: Layout 'post' requested in _posts/2015-11-07-the-case-for-nested-methods-in-ruby.md does not exist. What's happening here? Are all the

Bundler could not find compatible versions for gem “bundler”: In Gemfile:

扶醉桌前 提交于 2020-01-23 02:27:25
问题 I'm making GitHub blog page with Jekyll. I've failed like numerous times and just forked new one and followed README on the repository. It's https://github.com/janczizikow/sleek/blob/master/README.md and I tried to run Inside the directory(master) but this msg keeps coming out. I tried 'gem install bundler' 'gem cleanup' and similar solutions on the internet but still can't fix it. I get that I need another version which is lower one, then how can I remove the current one and install the

Get Jekyll Configuration Inside Plugin

喜你入骨 提交于 2020-01-22 17:15:07
问题 I'd like to make changes to the Jekyll Only First Paragraph plugin to make the generation of a 'read more ' link a configurable option. To do this I'd need to be able to access the Jekyll site config inside the plugin's AssetFilter . With the configuration available I can make the change. I don't know how to make the site configuration available to the plugin. The code below demonstrates where I'd like site.config available: require 'nokogiri' module Jekyll module AssetFilter def only_first_p

jekyll plugin not work on github

穿精又带淫゛_ 提交于 2020-01-21 11:24:07
问题 I want to change the order of pages in navitation bar by using jekyll-plugins / weighted_pages.rb from here. This plugin work very well on my localhost but github. I find the navitation bar is empty on github host, which seems this plugin does not work. How can I solve this problem? I copy weighted_pages.rb code below: # Generates a copy of site.pages as site.weighted_pages # with pages sorted by weight attribute. Pages with no # weight specified are placed after the pages with specified

How can I access un-rendered (markdown) content in Jekyll with liquid tags?

血红的双手。 提交于 2020-01-20 04:36:28
问题 From reading the documentation Jekyll's template data one might think that the way to access un-rendered content would be page.content ; but as far as I can tell, this is providing the content of the post as already rendered by the markdown parser. I need a solution that accesses the raw (original markdown) content directly, rather than simply trying to convert the html back to markdown. Background on use case My use case is the following: I use the pandoc plugin to render markdown for my

jekyll 完整安装教程

最后都变了- 提交于 2020-01-19 13:27:01
我的操作环境 CentOS主机: LSB Version: :core-4.1-amd64:core-4.1-noarch Distributor ID: CentOS Description: CentOS Linux release 7.4.1708 (Core) Release: 7.4.1708 Codename: Core 1. 安装ruby(同时会自动安装gem) 有ruby者,跳过此步骤! - 查看电脑是否有ruby $ ruby -v 安装 $ yum install ruby 查看ruby版本 $ ruby -v 输出 ruby 2.0.0p648 (2015-12-16) [x86_64-linux] jekyll 最新版要求 ruby 2.1或更高,所以更新ruby 这里我使用rvm更新ruby 安装rvm $ gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 $ curl -sSL https://get.rvm.io | bash -s stable $ source ~/.bashrc $ source ~/.bash_profile $ source /etc/profile.d/rvm.sh 修改rvm 的镜像到国内 $

博客搭建教程-Github Pages,jekyll,自定义域名

纵饮孤独 提交于 2020-01-19 00:27:10
基于GitHub Pages,jekyll,自定义域名-博客搭建 1. 前提 要有GitHub账号,理解GitHub Pages原理) 安装jekyll(便于后期在本地实时查看博客修改效果) 要有域名(目前国内:对于类似GitHub主机在外国的,域名可以不用备案) 2. 将jekyll网站模板放到自己的Github仓库中 http://jekyllthemes.org/ 此网站提供有可以直接使用的模板,直接下载后解压放到Github仓库里 3. 修改配置文件,实现网站特效 关于配置文件各参数介绍,可以去jekyll官网查看( https://www.jekyll.com.cn/docs/ ) 下面介绍主要的配置文件: **_config.yml **主要配置参数说明: # 用于自定义域名 url: https://www.liuwc.xyz/ # 这里写你自己的域名(要是使用GitHub提供的默然域名,可不填写) baseurl: / # for example, '/blog' if your blog hosted on 'host/blog'(这里如果写错,会导致后期网站样式加载不出来,因为路径错误) #其它配置参数,根据不同模板书写 CNAME 文档内容如下 www.liuwc.xyz # 写入自己的域名 4. 配置GitHub Pages 如图 [外链图片转存失败

Jekyll总结

若如初见. 提交于 2020-01-18 23:55:49
jekyll学习总结 1, {{ site.属性名 }} _config.yml文件中添加的任何属性都可以通过site命名空间访问 2, {{ page.属性名 }} 页面前端的任何属性都可以通过page命名空间访问 3, _posts 按照标准 YYYY-MM-DD-title.md 发布文章格式 4, layout多层嵌套 [外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-A5a1N5s5-1578729189473)(https://github.com/bigdatajava/blogspot/raw/master/img/tuchuang/jekyll1.png)] 在此示例中, document.md指定的Markdown文档中的内容layout: docs被推送到{{ content }}布局文件的标记中docs.html 由于docs布局本身指定layout: page,因此内容docs.html将被推入{{ content }}布局文件中的标记中page.html 最后因为page布局指定layout: default,内容page.html将被推入{{ content }}布局文件的标记中default.html 您不需要多个布局。你可以用一个:default 您可以选择如何设计网站 通常