Skip to content

Instantly share code, notes, and snippets.

@scaomath
Last active June 17, 2021 19:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save scaomath/1ba4546a2ae8b57a9ce89cfedfa674fb to your computer and use it in GitHub Desktop.
Save scaomath/1ba4546a2ae8b57a9ce89cfedfa674fb to your computer and use it in GitHub Desktop.
Jekyll simple workflow to use custom a plugin on Github pages

Jekyll simple workflow to use custom a plugin on Github pages

Workflow

Mainly following Alexandre Rademaker's guide.

  • Checkout to source branch, where we write things with a custom plugin.
git checkout source
  • Writing things, commit and push the changes
  • Build site into _site folder, _site folder should be in the .gitignore of the source branch
bundle exec jekyll serve
  • Change to master branch, add .nojekyll as one include in the _config.yml
git checkout master
cp -r _site/* . && rm -rf _site/ && touch .nojekyll
git add .
git commit
git push --all origin

Note

In another guide by Drew Silcock, the _site folder itself is linked the remote origin/master, however, as of right now, --set-upstream is not workin in git anymore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment