nanoc environments \o/
This commit is contained in:
parent
513a60f95d
commit
fd35397c04
5 changed files with 17 additions and 13 deletions
|
@ -14,9 +14,9 @@ before_install:
|
||||||
- echo -e "Host zeus.ugent.be\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
|
- echo -e "Host zeus.ugent.be\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
|
||||||
- npm install
|
- npm install
|
||||||
script:
|
script:
|
||||||
- ZEUS_PRODUCTION=1 bundle exec nanoc
|
- bundle exec nanoc --env=prod
|
||||||
- ZEUS_PRODUCTION=1 bundle exec nanoc check --deploy
|
- bundle exec nanoc --env=prod check --deploy
|
||||||
after_success:
|
after_success:
|
||||||
- mv deploy_key ~/.ssh/id_rsa
|
- mv deploy_key ~/.ssh/id_rsa
|
||||||
- chmod 600 ~/.ssh/id_rsa
|
- chmod 600 ~/.ssh/id_rsa
|
||||||
- '[[ $TRAVIS_PULL_REQUEST == "false" ]] && [[ $TRAVIS_BRANCH == "master" ]] && ZEUS_PRODUCTION=1 bundle exec nanoc deploy public'
|
- '[[ $TRAVIS_PULL_REQUEST == "false" ]] && [[ $TRAVIS_BRANCH == "master" ]] && bundle exec nanoc --env=prod deploy public'
|
||||||
|
|
2
Gemfile
2
Gemfile
|
@ -1,7 +1,7 @@
|
||||||
# frozen_string_literal: true
|
# frozen_string_literal: true
|
||||||
source 'https://rubygems.org'
|
source 'https://rubygems.org'
|
||||||
|
|
||||||
gem 'nanoc', '4.3.7'
|
gem 'nanoc', '4.4.1'
|
||||||
gem 'kramdown'
|
gem 'kramdown'
|
||||||
gem 'coffee-script'
|
gem 'coffee-script'
|
||||||
gem 'sass'
|
gem 'sass'
|
||||||
|
|
14
Gemfile.lock
14
Gemfile.lock
|
@ -3,7 +3,7 @@ GEM
|
||||||
specs:
|
specs:
|
||||||
adsf (1.2.1)
|
adsf (1.2.1)
|
||||||
rack (>= 1.0.0)
|
rack (>= 1.0.0)
|
||||||
autoprefixer-rails (6.5.1.1)
|
autoprefixer-rails (6.5.3)
|
||||||
execjs
|
execjs
|
||||||
builder (3.2.2)
|
builder (3.2.2)
|
||||||
coderay (1.1.1)
|
coderay (1.1.1)
|
||||||
|
@ -28,17 +28,17 @@ GEM
|
||||||
shellany (~> 0.0)
|
shellany (~> 0.0)
|
||||||
thor (>= 0.18.1)
|
thor (>= 0.18.1)
|
||||||
guard-compat (1.2.1)
|
guard-compat (1.2.1)
|
||||||
guard-nanoc (2.1.0)
|
guard-nanoc (2.1.1)
|
||||||
guard (~> 2.8)
|
guard (~> 2.8)
|
||||||
guard-compat (~> 1.0)
|
guard-compat (~> 1.0)
|
||||||
nanoc (~> 4.0)
|
nanoc (>= 4.3.8, < 5.0)
|
||||||
hamster (3.0.0)
|
hamster (3.0.0)
|
||||||
concurrent-ruby (~> 1.0)
|
concurrent-ruby (~> 1.0)
|
||||||
highline (1.7.8)
|
highline (1.7.8)
|
||||||
icalendar (2.4.1)
|
icalendar (2.4.1)
|
||||||
json (2.0.2)
|
json (2.0.2)
|
||||||
kramdown (1.12.0)
|
kramdown (1.13.0)
|
||||||
libv8 (3.16.14.15)
|
libv8 (3.16.14.17)
|
||||||
listen (3.1.5)
|
listen (3.1.5)
|
||||||
rb-fsevent (~> 0.9, >= 0.9.4)
|
rb-fsevent (~> 0.9, >= 0.9.4)
|
||||||
rb-inotify (~> 0.9, >= 0.9.7)
|
rb-inotify (~> 0.9, >= 0.9.7)
|
||||||
|
@ -46,7 +46,7 @@ GEM
|
||||||
lumberjack (1.0.10)
|
lumberjack (1.0.10)
|
||||||
method_source (0.8.2)
|
method_source (0.8.2)
|
||||||
mini_portile2 (2.1.0)
|
mini_portile2 (2.1.0)
|
||||||
nanoc (4.3.7)
|
nanoc (4.4.1)
|
||||||
cri (~> 2.3)
|
cri (~> 2.3)
|
||||||
hamster (~> 3.0)
|
hamster (~> 3.0)
|
||||||
parallel (~> 1.9)
|
parallel (~> 1.9)
|
||||||
|
@ -93,7 +93,7 @@ DEPENDENCIES
|
||||||
highline
|
highline
|
||||||
icalendar
|
icalendar
|
||||||
kramdown
|
kramdown
|
||||||
nanoc (= 4.3.7)
|
nanoc (= 4.4.1)
|
||||||
sass
|
sass
|
||||||
terminal-notifier-guard
|
terminal-notifier-guard
|
||||||
therubyracer
|
therubyracer
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
module EnvironmentHelper
|
module EnvironmentHelper
|
||||||
def production?
|
def production?
|
||||||
ENV['ZEUS_PRODUCTION']
|
ENV['NANOC_ENV'] == 'prod'
|
||||||
end
|
end
|
||||||
|
|
||||||
def development?
|
def development?
|
||||||
|
|
|
@ -3,7 +3,11 @@ title: Zeus WPI
|
||||||
author_name: ''
|
author_name: ''
|
||||||
author_uri: ''
|
author_uri: ''
|
||||||
|
|
||||||
base_url: https://zeus.ugent.be
|
base_url: http://localhost:3000
|
||||||
|
|
||||||
|
environments:
|
||||||
|
prod:
|
||||||
|
base_url: https://zeus.ugent.be
|
||||||
|
|
||||||
# The syntax to use for patterns in the Rules file. Can be either `"glob"`
|
# The syntax to use for patterns in the Rules file. Can be either `"glob"`
|
||||||
# (default) or `"legacy"`. The former will enable glob patterns, which behave
|
# (default) or `"legacy"`. The former will enable glob patterns, which behave
|
||||||
|
|
Loading…
Reference in a new issue