Install system dependencies
sudo apt-get update
sudo apt-get install git git-core curl libssl-dev libreadline-dev libyaml-dev python-software-properties
sudo apt-get install libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev libcurl4-openssl-dev libffi-dev
sudo apt-get install zlib1g-dev build-essential patch ruby-dev liblzma-dev
Install and configure rbenv
cd ~/
git clone https://github.com/rbenv/rbenv.git ~/.rbenv
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc
echo 'eval "$(rbenv init -)"' >> ~/.bashrc
exec $SHELL
git clone https://github.com/rbenv/ruby-build.git ~/.rbenv/plugins/ruby-build
echo 'export PATH="$HOME/.rbenv/plugins/ruby-build/bin:$PATH"' >> ~/.bashrc
exec $SHELL
git clone https://github.com/rbenv/rbenv-gem-rehash.git ~/.rbenv/plugins/rbenv-gem-rehash
Install ruby 2.2.2
rbenv install 2.2.2
rbenv global 2.2.2
ruby -v
Install bundler
gem install bundler
rbenv rehash
Install jekyll
gem install jekyll
Install btsync
sudo gedit /etc/apt/sources.list
Append the following line, then save and close:
deb http://linux-packages.getsync.com/btsync/deb btsync non-free
Next, do the install
wget http://linux-packages.getsync.com/btsync/key.asc
sudo apt-key add key.asc
sudo apt update
sudo apt install btsync
sudo systemctl enable btsync
sudo systemctl start btsync
systemctl status btsync
You can view the btsync gui by opening http://127.0.0.1:8888
Request a link to the unfoldingWord assets share and set it up to sync into the /var/www/projects/unfoldingWord.github.io/assets/
directory
Get the project from Github
git clone -v --progress [email protected]:unfoldingWord/unfoldingWord.github.io.git /var/www/projects/unfoldingWord.github.io
Open the project in IntelliJ/RubyMine
- Start IntelliJ or RubyMine.
- Click
File
>New
>Project
. - Select
Ruby
and clickNext
. - Choose
/var/www/projects/unfoldingWord.github.io
as the project location. - Click
Finish
. - Install missing gems if prompted.
- Run
bundle install
in the IntelliJ/RubyMine terminal.
Create a Run configuration
- Click
Run
>Edit Configurations...
. - Click the
green plus sign
and add a newRuby
configuration. - In the
Name
field enterBuild and Serve
. - In the
Ruby script
field enter/home/team43/.rbenv/versions/2.2.2/bin/jekyll
, replacingteam43
with your username. - In the
Script arguments
field enterserve --no-watch
. - Remove everything from the
Before launch: activate tool window
list. - Click on the
bundler
tab and checkRun script in the context of bundle
. - Click
OK
to save and close the dialog.