diff --git a/Jenkinsfile b/Jenkinsfile index cecdb3c7b..a2907f0b6 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -49,9 +49,8 @@ try { checkout scm } - stage('Build site') { - /* If the slave can't gather resources and build the site in 60 minutes, + /* If the agent can't gather resources and build the site in 60 minutes, * something is very wrong */ timeout(60) { @@ -60,6 +59,14 @@ try { set -o nounset set -o pipefail set -o xtrace + make update + if ! git diff-index --quiet HEAD -- Gemfile.lock package-lock.json ; then + echo "A node or ruby dependency has changed." + git diff + echo "Run 'make update' and commit resulting changes." + exit 1 + fi + mkdir -p build make all 2>&1 | tee build/log.txt if [[ -n "$( grep --fixed-strings WARNING build/log.txt | grep --fixed-strings --invert-match user-handbook.adoc | grep --fixed-strings --invert-match 'conversion missing in backend pdf' )" ]] ; then diff --git a/Makefile b/Makefile index 2ab94d359..9fc15d585 100644 --- a/Makefile +++ b/Makefile @@ -51,6 +51,11 @@ $(OUTPUT_DIR)/releases.rss: $(OUTPUT_DIR) scripts/release.rss.groovy ####################################################### depends: depends-ruby depends-node +# update dependencies information +update: + ./scripts/ruby bundle update + ./scripts/node npm update + depends-ruby: vendor/gems vendor/gems: Gemfile Gemfile.lock @@ -60,8 +65,8 @@ vendor/gems: Gemfile Gemfile.lock depends-node: node_modules node_modules: package.json package-lock.json - ./scripts/node npm install - @touch node_modules + ./scripts/node npm install + @touch node_modules assets: depends-node mkdir -p $(ASSETS_DIR) @@ -106,4 +111,4 @@ clean: ####################################################### .PHONY: all archive assets clean depends depends-node depends-ruby \ - fetch fetch-reset generate pdfs prepare run site + fetch fetch-reset generate pdfs prepare run site update diff --git a/package.json b/package.json index ca77d2d51..4f6f617cf 100644 --- a/package.json +++ b/package.json @@ -5,10 +5,10 @@ "keywords": [], "author": "", "dependencies": { - "bootstrap": "4.0.0-alpha.6", "anchor-js": "3.2.2", - "tether": "1.4.0", - "ionicons": "2.0.1" + "bootstrap": "4.0.0-alpha.6", + "ionicons": "2.0.1", + "tether": "1.4.0" }, "homepage": "https://jenkins.io" }