Skip to content

Commit

Permalink
CI: Ensure static react-app is checked in (thanos-io#7063)
Browse files Browse the repository at this point in the history
* 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 <[email protected]>

* 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 <[email protected]>

---------

Signed-off-by: Jacob Baungard Hansen <[email protected]>
  • Loading branch information
jacobbaungard authored and jnyi committed Apr 4, 2024
1 parent 6798023 commit 5117a96
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/react.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,5 @@ jobs:
restore-keys: |
${{ runner.os }}-node-
- run: CI=false make check-react-app
- run: make react-app-test
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down

0 comments on commit 5117a96

Please sign in to comment.