Skip to content

tonycodurance/site

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Setup the development writing environment

You can serve the site through docker or natively on your machine.

Installing if you like Docker

TL;DR
  1. install docker
  • docker build --tag codurance-site:local -f ./Dockerfile-local .
  • docker run -i -t -v `pwd`:/site -p 4000:4000 codurance-site:local
More details

You need to execute the following command to prepare an image and run a container:

# you need to do this only once - this builds the container with all the dependencies for running the site
docker build --tag codurance-site:local -f ./Dockerfile-local .
# you need to run this every time you want to stand up the local server - it should watch for changes in the local files automatically though
docker run -i -t -v `pwd`:/site -p 4000:4000 codurance-site:local 

If you want to run a different rake target on the container start use:

docker run -i -t -v `pwd`:/site -p 4000:4000 -e RAKE_TARGET="your_target" codurance-site:local

Installing if you like ruby

  1. install rvm https://rvm.io/
  • rvm install ruby
  • rvm use ruby
  • gem install bundler
  • bundle install

run locally:

  1. bundle exec rake servequick

In case of other problems, refer to the troubleshooting section.

Flight Rules

Adding a post

  • Remember to add the tag asset-type: post to the post metadata

Adding an abstract to a post

  • See Jenkins example post, especially the abstract field.
  • Note: comments can only be single line
  • Note: Even if they are too long, they'll be cut to 30 words

Adding a video to the publications

  • Add an md file to the folder: videos/_posts (You can use older videos post as a template)
  • Do not forget the attribute video-url, for youtube videos, use following format: https://www.youtube.com/embed/
  • Add an image to the video, for youtube videos, make a screenshot here, the image is used on the home page and the carousel. The image is to be saved under /assets/custom/img/videos/

Previewing changes for a pull request

illustration of how to go the site preview

We have a bot that makes a preview of the site for every branch that you create.

If you don't have a PR, you can just replace the branch name in the link below:

http://codurance-site-pr.s3-website-eu-west-1.amazonaws.com/site-[branch-name]

Troubleshooting

Header files for ruby not found

This problem happens with Linux systems:

header files for ruby at /usr/lib/ruby/include/ruby.h not found

in case ruby-dev package is not installed:

sudo apt-get install ruby-dev

extconf.rb failed

zlib is necessary for building libxml2:

sudo apt-get install zlib1g-dev

Gem problems?

If other things don't make sense - follow this guide to clear out your cached gems and start the process again: https://coderwall.com/p/x3z2ag/cleanup-rvm

Releases

No releases published

Packages

No packages published

Languages

  • HTML 65.2%
  • CSS 20.7%
  • JavaScript 13.8%
  • PHP 0.1%
  • Python 0.1%
  • Ruby 0.1%