Coder Social home page Coder Social logo

erin-bristow.github.io's Introduction

erin-bristow.github.io

Personal blog/resume website using samarsault's texture theme for Jekyll.

https://jekyllrb.com/docs/configuration/

https://github.com/samarsault/texture

Note on Custom Plugins

I wanted to use custom plugins (notably, jekyll-target-blank), but GitHub Pages doesn't allow custom plugins by default, citing security concerns. For more control over your site, including the use of custom plugins, you can deploy your Jekyll site to GitHub Pages with GitHub Actions. Below are a few issues I ran into when following the Jekyll documentation for GitHub Actions. Hopefully this can help you with troubleshooting your own site.

  1. After the gh-pages branch is created, you must switch to the gh-pages branch in the settings for your GitHub Pages repository.
  2. In github-pages.yml, you need to include target_branch: gh-pages but that's the only line I had to change in the documentation's provided github-pages.yml file.
  3. There can be issues with custom domains. The CNAME record will not be automatically placed in the new gh-pages branch, and you cannot manually create the CNAME record file in the gh-pages branch because it will be overwritten every time your site is rebuilt. In your Jekyll _config.xml file you need to add include: CNAME to force Jekyll to include that record in the gh-pages branch.

A final note: Even though GitHub pages is now serving your site off of the gh-pages branch and not master, you still need to be pushing to your master branch. When you push to your master branch, GitHub Actions will automatically build the site in the gh-pages branch. Do not edit the gh-pages branch directly because your changes will not persist when your site is rebuilt.

Jekyll + GitHub Pages on Arch Linux

GitHub Pages uses Ruby 2.7.4 as of Dec 2022. The most recent version of Ruby is 3.1, which Jekyll will use by default. Since I'm using EndeavourOS right now, I needed to downgrade to 2.7 so I could locally run my Jekyll blog. The below steps were mostly taken from this writeup. I must have had to do something similar on Windows, but I think there are a lot more guides for that OS so it was less of a pain.

yay -S ruby2.7 ruby2.6-bundler
alias ruby=ruby-2.7 
alias gem=gem-2.7 
export PATH=/home/$USER/.gem/ruby/2.7.0/bin:$PATH
gem-2.7 install jekyll bundler --user-install

The alias didn't work (I probably forgot to restart my terminal? idk, don't remember) but calling gem-2.7 explicitly was fine.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.