From 96b44b7e938f1f64c815ce05b89f58f44d5f4991 Mon Sep 17 00:00:00 2001 From: Colin Casey Date: Fri, 4 Oct 2024 16:56:03 -0300 Subject: [PATCH] Suggested changes for CI and release automation Splits the npm scripts into primary development tasks and lifecycle scripts: - `build` - `precommit`: Rebuilds all generated files - `prepack`: Lifecycle script to guarantee compiled files are up-to-date before publishing - `test` - `version`: Lifecycle script to guarantee all files affected by a version bump are regenerated and added to git All other scripts are prefixed with `_` to distinguish between the high-level development tasks above and smaller tasks that can be used as building blocks. Also included in this PR: - extracted the inline script that would check if any generated files had not been committed to `validate-generated-files.sh` --- .github/workflows/integration.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/integration.yaml b/.github/workflows/integration.yaml index 4456bd16..e29c28e8 100644 --- a/.github/workflows/integration.yaml +++ b/.github/workflows/integration.yaml @@ -40,7 +40,7 @@ jobs: run: | npm ci npm run build - echo "tough_cookie_tarball=$(npm pack)" >> "$GITHUB_OUTPUT" + echo "tough_cookie_tarball=$(npm pack | tail -1)" >> "$GITHUB_OUTPUT" working-directory: ./tough-cookie - name: Setup HOSTS file for Web Platform Test server run: ./test/web-platform-tests/tests/wpt make-hosts-file | sudo tee -a /etc/hosts @@ -76,7 +76,7 @@ jobs: run: | npm ci npm run build - echo "tough_cookie_tarball=$(npm pack)" >> "$GITHUB_OUTPUT" + echo "tough_cookie_tarball=$(npm pack | tail -1)" >> "$GITHUB_OUTPUT" working-directory: ./tough-cookie - name: Setup HOSTS file for Web Platform Test server run: ./test/web-platform-tests/tests/wpt make-hosts-file | sudo tee -a /etc/hosts