From 49bb4ee1ed25b9a47e2a78589d7284fe3ed3ede4 Mon Sep 17 00:00:00 2001 From: Simon Flower Date: Thu, 31 Aug 2023 13:03:34 +0100 Subject: [PATCH] Update project documentation for installing Ruby (#74) --- .gitignore | 1 + Gemfile | 2 ++ contributing.md | 18 ++++++++++++++++++ requirements.yml | 8 ++++++++ 4 files changed, 29 insertions(+) create mode 100755 requirements.yml diff --git a/.gitignore b/.gitignore index c7f034f..cde4528 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ .DS_Store _site Gemfile.lock +.bundle diff --git a/Gemfile b/Gemfile index 37f5eaa..7a42359 100644 --- a/Gemfile +++ b/Gemfile @@ -1,2 +1,4 @@ source 'https://rubygems.org' gem 'github-pages', group: :jekyll_plugins + +gem "webrick", "~> 1.8" diff --git a/contributing.md b/contributing.md index d45aa5a..e862274 100644 --- a/contributing.md +++ b/contributing.md @@ -57,6 +57,11 @@ More information on grip [here](https://github.com/joeyespo/grip). 1. If you don't have Ruby installed, install Ruby 2.1.0 or higher from [here](https://www.ruby-lang.org/en/downloads/). +For Debian 10, you can do this: +```bash +sudo apt-get install ruby ruby-dev make gcc g++ zlib1g zlib1g-dev git +``` + 2. Using a command shell go to the folder that contains the cloned copy of the repository on your computer and type these commands to install Jekyll: ```bash @@ -64,12 +69,25 @@ gem install bundler bundle install ``` +On a Debian 10 machine where you don't have access to system resources, you can do this instead: + +```bash +gem install bundler --user-install +~/.gem/ruby/2.5.0/bin/bundle install --path ~/.gem/ +``` + 3. Run Jekyll like this (from the same folder as step 2). This will also compile any changes you make to Jekyll files and send them to the target web site: ```bash bundle exec jekyll serve +``` + +For the Debian 10 install above, the command to run Jekyll is: + +```bash +~/.gem/ruby/2.5.0/bin/bundle exec jekyll serve ``` More information on Jekyll [here](https://help.github.com/articles/setting-up-your-github-pages-site-locally-with-jekyll/). diff --git a/requirements.yml b/requirements.yml new file mode 100755 index 0000000..db6ddd7 --- /dev/null +++ b/requirements.yml @@ -0,0 +1,8 @@ +# conda requirements file to create virtual environment for INTERMAGNET web site +# use like this: conda env create -f requirements.yml +name: intermagnet.github.io +dependencies: + - python=3.6 + - pip: + - grip==4.5.2 +