https://styleguide.adhoc.team/ - the Ad Hoc Style guide
https://styleguide.adhoc.team/
is a
Jekyll site.
-
Install Ruby. The website is a Jekyll site. Jekyll requires Ruby, version 2.0 or newer.
-
Install bundler. Do:
gem install bundler
-
Checkout the source. Do:
git checkout git@github.com:adhocteam/styleguide.git
-
Install Jekyll and its dependencies. Do:
cd styleguide && bundle install
- Run Jekyll. Do:
bundle exec jekyll build
. The generated site will be in the_site
directory. You can browse that directory using something likepython -m SimpleHTTPServer
and going tohttp://localhost:8000/
, or you can dobundle exec jekyll serve
instead ofbuild
and go tohttp://localhost:4000/
. This will keep a persistent process around and rebuild the site when source files change, too.
The workflow for publishing the site is: commit changes to the source code with git, create a pull request on the GitHub project, get it reviewed and merged, and then the Codeship CI service will run Jekyll and push the artifact to an AWS S3 bucket in Ad Hoc’s account. On the VM instance where the site is served, the content is synced from the S3 bucket every few minutes, and served with nginx.
-
Create a new git branch for the changes. Do:
git checkout -b your-branch-name
-
Make your changes. Add the blog post, edit a page, change an image, etc.
-
Rebuild the site locally and review.
-
Commit your changes with git. Do:
git commit -a -m “useful commit message here”
-
Push your changes to GitHub and open a pull request. Do:
git push origin your-branch-name
-
Assign another Ad Hoc team member to review your pull request.
-
Merge the pull request. You might need to ask someone with permission to do that.
-
Refresh
styleguide.adhoc.team
to confirm your change. It may take 5 minutes for the change to sync.
You’re done! 😃