From 3de122f3311ad5ff29fc53c77ad7040514161e99 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacob=20Baung=C3=A5rd=20Hansen?= Date: Tue, 16 Jan 2024 11:53:12 +0100 Subject: [PATCH] CI: Ensure static react-app is checked in (#7063) * CI: Ensure static react-app is checked in With this commit the CI system should fail if changes to the react-app has been made without checking in the changes. Signed-off-by: Jacob Baungard Hansen * Add `react-app` as dependency `check-react-app` To ensure the react-app is rebuilt before checking for changes. Signed-off-by: Jacob Baungard Hansen --------- Signed-off-by: Jacob Baungard Hansen --- .github/workflows/react.yml | 1 + Makefile | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/.github/workflows/react.yml b/.github/workflows/react.yml index 97a818917d..cf20772f4b 100644 --- a/.github/workflows/react.yml +++ b/.github/workflows/react.yml @@ -29,4 +29,5 @@ jobs: restore-keys: | ${{ runner.os }}-node- + - run: CI=false make check-react-app - run: make react-app-test diff --git a/Makefile b/Makefile index 9f40fa3e7f..bee70ee848 100644 --- a/Makefile +++ b/Makefile @@ -121,6 +121,10 @@ $(REACT_APP_OUTPUT_DIR): $(REACT_APP_NODE_MODULES_PATH) $(REACT_APP_SOURCE_FILES .PHONY: react-app react-app: $(REACT_APP_OUTPUT_DIR) +.PHONY: check-react-app +check-react-app: react-app + $(call require_clean_work_tree,'all generated files should be committed, run make react-app and commit changes.') + .PHONY: react-app-lint react-app-lint: $(REACT_APP_NODE_MODULES_PATH) @echo ">> running React app linting"