Skip to content

Commit

Permalink
Ensure watchman watch is removed after Jenkins build
Browse files Browse the repository at this point in the history
  • Loading branch information
Pedro Pombeiro committed Jun 12, 2019
1 parent f3aa376 commit 8a1ef0d
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 21 deletions.
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,9 @@ clean-nix: SHELL := /bin/sh
clean-nix: ##@prepare Remove complete nix setup
sudo rm -rf /nix ~/.nix-profile ~/.nix-defexpr ~/.nix-channels ~/.cache/nix ~/.status .nix-gcroots

watchman-clean:
watchman watch-del $(PWD)

add-gcroots: ##@prepare Add Nix GC roots to avoid status-react expressions being garbage collected
scripts/add-gcroots.sh

Expand Down
1 change: 1 addition & 0 deletions ci/Jenkinsfile.android
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ pipeline {
}
stage('Cleanup') {
steps {
sh 'watchman watch-del $PWD'
sh 'make clean'
}
}
Expand Down
1 change: 1 addition & 0 deletions ci/Jenkinsfile.ios
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ pipeline {
}
stage('Cleanup') {
steps {
sh 'watchman watch-del $PWD'
sh 'make clean'
}
}
Expand Down
1 change: 1 addition & 0 deletions ci/Jenkinsfile.linux
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ pipeline {
}
stage('Cleanup') {
steps {
sh 'watchman watch-del $PWD'
sh 'make clean'
}
}
Expand Down
1 change: 1 addition & 0 deletions ci/Jenkinsfile.macos
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ pipeline {
}
stage('Cleanup') {
steps {
sh 'watchman watch-del $PWD'
sh 'make clean'
}
}
Expand Down
1 change: 1 addition & 0 deletions ci/Jenkinsfile.windows
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ pipeline {
}
stage('Cleanup') {
steps {
sh 'watchman watch-del $PWD'
sh 'make clean'
}
}
Expand Down
21 changes: 0 additions & 21 deletions ci/desktop.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -3,27 +3,6 @@ utils = load 'ci/utils.groovy'

packageFolder = './StatusImPackage'

def installJSDeps(platform) {
def attempt = 1
def maxAttempts = 10
def installed = false
/* prepare environment for specific platform build */
nix.shell "scripts/prepare-for-platform.sh ${platform}"
while (!installed && attempt <= maxAttempts) {
println "#${attempt} attempt to install npm deps"
nix.shell 'yarn install --frozen-lockfile'
installed = fileExists('node_modules/web3/index.js')
attemp = attempt + 1
}
}

def cleanupAndDeps() {
sh 'make clean'
sh 'cp .env.jenkins .env'
nix.shell 'lein deps'
installJSDeps('desktop')
}

def buildClojureScript() {
nix.shell(
'''
Expand Down

0 comments on commit 8a1ef0d

Please sign in to comment.