The code repo for the LFE News & Updates Blog
We welcome blog contributors! Just fork the repo, write your post, and submit a PR.
You can view the blog here. The LFE blog is a member of Planet Erlang.
The make
targets for this repo all utilize Docker; this way, contributors
don't have to install specififc versions of Ruby, Jekyll, etc., ad naseum et
insaniam.
The most recent "release" of the published blog is visible in the generated
directory. This is actually a git submodule that points to the gh-pages
branch; it's content is dynamic and should not be edited.
- Fork this repo (you might want to rename yours from "blog" to "lfe-blog")
- See the usage below to create a post
- Push to your fork
- Issue a PR from your branch to lfe/blog
master
Details of these steps are given below, in the following subsections.
-
Update the name in your new repo's settings, changing from "blog" to "lfe-blog"
-
Clone:
$ git clone --recurse-submodules [email protected]:<YOURNAME>/lfe-blog.git $ cd lfe-blog
$ TITLE="Exciting LFE News" make new
If you have your $EDITOR
env var set, you can make post
instead, and the
post stub will open in your editor.
Edit to your heart's content. Be sure to update the following:
- Category (theme of your post)
- Descriptive tags
- Your name as
author
$ git add src/_posts/2014-12-04-1323-exciting-lfe-news.md
Also at this point you'll want to add any new directories that were created,
e.g., for tags, archives, years, etc. Make sure you didn't miss anything by
checkout the untracked files in the git status
output.
Once you're stasified with your post, push your branch up to your fork of
the blog and issue a PR to be merged with master
of lfe/blog.
- Merge a contributor's PR
- Regenerate the static content
- Push the updated static content to
gh-pages
Note that if you haven't updated your local clone of the LFE Blog repo after May 2019, you'll need to do the following:
$ git submodule update --init --recursive
Once a contributor's code has been merged (either in the Web UI or via
command line), you are ready to publish. This needs to be done locally,
so if you've merged a PR on Github, you'll need to $ git pull origin master
.
The following command will regenerate the static content, commit it to
master (interactively), and then push the static content to gh-pages
for the LFE blog repo on github (which will be renderable immediately on
the blog):
$ make publish
To create a new post:
$ TITLE="Super-Sweet LFE Tutorial" make new
This will open a draft with vi
. Edit to your heart's content, save, commit,
push, and send the PR!
Other useful make
targets:
Rebuild the site static files in the ./build
directory:
$ make build
Run a local copy of the site available on http://localhost:4000, served from
the ./build
directory:
$ make run
Clean up your build files:
$ make clean
Update your jekyll Ruby gem. This will also update your gems and install jekyll, if it's not already installed:
$ make update
Publish your changes to master
and gh-pages
:
$ make publish
This site is built using Jekyll-Bootstrap with a modified version of the Hooligan template.