Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make - add gradle assemble #80

Merged
merged 5 commits into from
Jan 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 15 additions & 7 deletions .github/workflows/build-and-test-backend.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,18 @@
name: "[Build & Test] Backend"

on:
# push:
# branches: [ "main" ]
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
workflow_dispatch:
schedule:
- cron: "0 3 * * *" # 3am every night

permissions:
contents: write
pull-requests: write

jobs:
build-and-test-backend:
runs-on: ubuntu-latest
Expand All @@ -21,16 +25,20 @@ jobs:
distribution: temurin
java-version: 17

- uses: gradle/[email protected]
id: setup-gradle
with:
gradle-version: wrapper

- name: Print JAVA_HOME
run: |
echo "JAVA_HOME is $JAVA_HOME"
echo "JAVA_HOME=$JAVA_HOME" >> $GITHUB_ENV

- name: cd backend
run: cd backend

- uses: gradle/[email protected]
id: setup-gradle
with:
gradle-version: wrapper
dependency-graph: generate-and-submit

- name: build and test
run: make back-build

Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/build-and-test-frontend.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
name: "[Build & Test] Frontend"

on:
# push:
# branches: [ "main" ]
# pull_request:
# branches: [ "main" ]
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
workflow_dispatch:
schedule:
- cron: "0 3 * * *" # 3am every night
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@
name: "[Analyse] CodeQL"

on:
# push:
# branches: ["main"]
# pull_request:
# branches: [ "main" ]
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
schedule:
- cron: "0 3 * * *" # 3am every night

Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/dependency-review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@
# Source repository: https://github.com/actions/dependency-review-action
# Public documentation: https://docs.github.com/en/code-security/supply-chain-security/understanding-your-software-supply-chain/about-dependency-review#dependency-review-enforcement
name: '[Analyse] Dependency Review'
on: [ pull_request ]
on:
pull_request:
workflow_dispatch:

permissions:
contents: read
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/sonarcloud.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ name: "[Analyse] SonarCloud"
on:
# push:
# branches: [ "main" ]
# pull_request:
# branches: [ "main" ]
# types: [ opened, synchronize, reopened ]
pull_request:
branches: [ "main" ]
types: [ opened, synchronize, reopened ]
schedule:
- cron: "0 3 * * *" # 3am every night
workflow_dispatch:
Expand Down
5 changes: 2 additions & 3 deletions .github/workflows/trivy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,8 @@ name: "[Analyse] Trivy"
on:
# push:
# branches: [ "main" ]
# pull_request:
# # The branches below must be a subset of the branches above
# branches: [ "main" ]
pull_request:
branches: [ "main" ]
workflow_dispatch:
schedule:
- cron: "0 3 * * *" # 3am every night
Expand Down
5 changes: 4 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,14 @@ front-visualize-bundle:
BACKEND_DIR := backend
BACKEND_CONFIGURATION_FOLDER=$(shell pwd)/infra/configurations/backend/

.PHONY: back-show-dependencies back-build back-test back-local
.PHONY: back-show-dependencies back-assemble back-build back-test back-local

back-show-dependencies:
cd $(BACKEND_DIR) && ./gradlew dependencies

back-assemble:
cd $(BACKEND_DIR) && ./gradlew assemble

back-build:
cd $(BACKEND_DIR) && ./gradlew build

Expand Down
Loading