From 40a656862f83cdf5e0ed6ec93e16f73e9e84370c Mon Sep 17 00:00:00 2001 From: Kai Arseneau Date: Tue, 19 Mar 2024 09:42:08 -0400 Subject: [PATCH] Updated workflows --- .github/workflows/ci.yaml | 18 ----------------- .github/workflows/maven.yaml | 8 ++------ .github/workflows/node.js.yaml | 35 ++++++++++++++++++++++++++++++++++ 3 files changed, 37 insertions(+), 24 deletions(-) delete mode 100644 .github/workflows/ci.yaml create mode 100644 .github/workflows/node.js.yaml diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml deleted file mode 100644 index 15a61d6..0000000 --- a/.github/workflows/ci.yaml +++ /dev/null @@ -1,18 +0,0 @@ -name: GitHub Actions Demo -run-name: ${{ github.actor }} is testing out GitHub Actions 🚀 -on: [push] -jobs: - Explore-GitHub-Actions: - runs-on: ubuntu-latest - steps: - - run: echo "🎉 The job was automatically triggered by a ${{ github.event_name }} event." - - run: echo "🐧 This job is now running on a ${{ runner.os }} server hosted by GitHub!" - - run: echo "🔎 The name of your branch is ${{ github.ref }} and your repository is ${{ github.repository }}." - - name: Check out repository code - uses: actions/checkout@v4 - - run: echo "💡 The ${{ github.repository }} repository has been cloned to the runner." - - run: echo "🖥️ The workflow is now ready to test your code on the runner." - - name: List files in the repository - run: | - ls ${{ github.workspace }} - - run: echo "🍏 This job's status is ${{ job.status }}." diff --git a/.github/workflows/maven.yaml b/.github/workflows/maven.yaml index f7b557f..5a600c5 100644 --- a/.github/workflows/maven.yaml +++ b/.github/workflows/maven.yaml @@ -29,10 +29,6 @@ jobs: java-version: '17' distribution: 'temurin' cache: maven - - - name: Build with Maven - run: cd ./API && mvn -B package --file pom.xml - # Optional: Uploads the full dependency graph to GitHub to improve the quality of Dependabot alerts this repository can receive - - name: Update dependency graph - uses: advanced-security/maven-dependency-submission-action@571e99aab1055c2e71a1e2309b9691de18d6b7d6 + - name: Build with Maven + run: cd ./API && mvn -B -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn package --file pom.xml diff --git a/.github/workflows/node.js.yaml b/.github/workflows/node.js.yaml new file mode 100644 index 0000000..9a099f7 --- /dev/null +++ b/.github/workflows/node.js.yaml @@ -0,0 +1,35 @@ +# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs + +name: Node.js CI + +on: [push] + # push: + # branches: [ "main" ] + # pull_request: + # branches: [ "main" ] + +jobs: + build: + runs-on: ubuntu-latest + name: "Build with Node.js" + + strategy: + matrix: + node-version: [14.x, 16.x, 18.x] + # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ + + steps: + - name: Check out repository code + uses: actions/checkout@v4 + + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + cache: 'npm' + + - run: cd ./front-end + - run: npm ci + - run: npm run build --if-present + - run: npm test \ No newline at end of file