This is an automated email from the ASF dual-hosted git repository. djencks pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/camel-website.git
commit 372871873f20880d50e4bc1c4d13474f408f3bad Author: David Jencks <[email protected]> AuthorDate: Mon Oct 25 07:47:09 2021 -0700 Add yarn install related scripts to package.json. Make pr build fail if yarn lock file change. Make Jenkinsfile rebuild dependencies to make it platform independent. --- .github/workflows/pr.yaml | 2 +- Jenkinsfile | 2 +- package.json | 3 +++ 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index e3f57d7..910410c 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -30,7 +30,7 @@ jobs: - name: Checkout uses: actions/checkout@v2 - name: Check cache - run: yarn workspaces foreach install --check-cache + run: yarn validate-deps - name: Build run: yarn build-all - name: Run checks diff --git a/Jenkinsfile b/Jenkinsfile index 5337770..1ba6fd5 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -57,7 +57,7 @@ pipeline { } steps { - sh "cd $WORKSPACE/camel-website && yarn clean; HUGO_PARAMS_GitHubUsername=$GITHUB_USR HUGO_PARAMS_GitHubToken=$GITHUB_PSW yarn build-all" + sh "cd $WORKSPACE/camel-website && yarn clean && yarn deps-rebuild-all; HUGO_PARAMS_GitHubUsername=$GITHUB_USR HUGO_PARAMS_GitHubToken=$GITHUB_PSW yarn build-all" } } diff --git a/package.json b/package.json index f5d979b..e5048c0 100644 --- a/package.json +++ b/package.json @@ -3,6 +3,9 @@ "version": "1.0.0-SNAPSHOT", "license": "Apache-2.0", "scripts": { + "update-deps": "yarn workspaces foreach install --check-cache", + "validate-deps": "yarn workspaces foreach install --check-cache --immutable", + "deps-rebuild-all": "yarn workspaces foreach rebuild", "build:antora": "antora --clean --fetch antora-playbook.yml --stacktrace", "build:hugo": "hugo --cacheDir ${HUGO_CACHE_DIR:-$(pwd)/.hugo_data} ${HUGO_OPTIONS:-}", "build:minify": "gulp minify",
