From a5e78825bc07d49d44cf508dd4392b808faed4c2 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 17:14:45 +0200 Subject: [PATCH 001/117] Testing Checkout --- .github/workflows/ci.yml | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000000..e83e62c628 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,39 @@ +# © 2024. TU Dortmund University, +# Institute of Energy Systems, Energy Efficiency and Energy Economics, +# Research group Distribution grid planning and operation +# + +name: CI + +on: + push: + branches: + - main + - dev + - 'feature/*' + - 'hotfix/*' + - 'release/*' + pull_request: + branches: + - main + - dev + + jobs: + checkout_code: + runs-on: ubuntu-latest + steps: + - name: Checkout Code + uses: actions/checkout@v4 + with: + # Check if it's a pull request + ref: ${{ github.event.pull_request.head.ref || github.ref }} + repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} + ssh-key: ${{ secrets.SSH_PRIVATE_KEY }} + + - name: Get Commit Hash + id: get_commit + run: echo "::set-output name=hash::$(git rev-parse HEAD)" + + - name: Display Commit Hash + run: + echo "Checked out commit hash: ${{ steps.get_commit.outputs.hash }}" \ No newline at end of file From c205a34cc360de7389638c61a2b1e90048b7a8b0 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 17:18:55 +0200 Subject: [PATCH 002/117] Fixed Syntax --- .github/workflows/ci.yml | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e83e62c628..2f32e94300 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -18,22 +18,22 @@ on: - main - dev - jobs: - checkout_code: - runs-on: ubuntu-latest - steps: - - name: Checkout Code - uses: actions/checkout@v4 - with: - # Check if it's a pull request - ref: ${{ github.event.pull_request.head.ref || github.ref }} - repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} - ssh-key: ${{ secrets.SSH_PRIVATE_KEY }} +jobs: + checkout_code: + runs-on: ubuntu-latest + steps: + - name: Checkout Code + uses: actions/checkout@v4 + with: + # Check if it's a pull request + ref: ${{ github.event.pull_request.head.ref || github.ref }} + repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} + ssh-key: ${{ secrets.SSH_PRIVATE_KEY }} - - name: Get Commit Hash - id: get_commit - run: echo "::set-output name=hash::$(git rev-parse HEAD)" + - name: Get Commit Hash + id: get_commit + run: echo "::set-output name=hash::$(git rev-parse HEAD)" - - name: Display Commit Hash - run: - echo "Checked out commit hash: ${{ steps.get_commit.outputs.hash }}" \ No newline at end of file + - name: Display Commit Hash + run: + echo "Checked out commit hash: ${{ steps.get_commit.outputs.hash }}" \ No newline at end of file From 0d7d2561083bc549d80ad9832c09318ac1f4799b Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 17:22:30 +0200 Subject: [PATCH 003/117] Fixed Syntax --- .github/workflows/ci.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2f32e94300..f6a83907d6 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -32,8 +32,10 @@ jobs: - name: Get Commit Hash id: get_commit - run: echo "::set-output name=hash::$(git rev-parse HEAD)" + run: | + COMMIT_HASH=$(git rev-parse HEAD) + echo "::set-output name=hash::$COMMIT_HASH" - name: Display Commit Hash run: - echo "Checked out commit hash: ${{ steps.get_commit.outputs.hash }}" \ No newline at end of file + echo "Checked out commit hash: ${{ steps.get_commit.outputs.hash }}" From 81864ff2214275dd0db7c021cc5f684e09d09e92 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 17:31:46 +0200 Subject: [PATCH 004/117] removed unnecessary steps --- .github/workflows/ci.yml | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f6a83907d6..9a843da33c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,13 +29,3 @@ jobs: ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} ssh-key: ${{ secrets.SSH_PRIVATE_KEY }} - - - name: Get Commit Hash - id: get_commit - run: | - COMMIT_HASH=$(git rev-parse HEAD) - echo "::set-output name=hash::$COMMIT_HASH" - - - name: Display Commit Hash - run: - echo "Checked out commit hash: ${{ steps.get_commit.outputs.hash }}" From e21113c23d8425f37d321d7e75b504a3fa5ec7f8 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 17:38:40 +0200 Subject: [PATCH 005/117] removed unnecessary steps --- .github/workflows/ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9a843da33c..7a7af82e40 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,3 +29,5 @@ jobs: ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} ssh-key: ${{ secrets.SSH_PRIVATE_KEY }} + run: + echo "Current branch: ${{ github.event.pull_request.head.ref || github.ref }}" From 1a322fe1169009c96b1300ec0baebb8c48b183bd Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 17:42:54 +0200 Subject: [PATCH 006/117] Syntax --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7a7af82e40..7fd03ae240 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,5 +29,6 @@ jobs: ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} ssh-key: ${{ secrets.SSH_PRIVATE_KEY }} + - name: Show current Branch run: echo "Current branch: ${{ github.event.pull_request.head.ref || github.ref }}" From a3581861705165c8f0321e2eeac288dcc2efb543 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 17:46:01 +0200 Subject: [PATCH 007/117] Syntax --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7fd03ae240..70b45ff4f7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -30,5 +30,5 @@ jobs: repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} ssh-key: ${{ secrets.SSH_PRIVATE_KEY }} - name: Show current Branch - run: - echo "Current branch: ${{ github.event.pull_request.head.ref || github.ref }}" + run: | + git rev-parse --abbrev-ref HEAD \ No newline at end of file From ef8ef612fb4a5e4a8064eb6c354cb1965333c193 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 17:57:04 +0200 Subject: [PATCH 008/117] Test SSH --- .github/workflows/ci.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 70b45ff4f7..5c5e4ebbad 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -22,6 +22,9 @@ jobs: checkout_code: runs-on: ubuntu-latest steps: + - name: Test SSH Key Authorization + if: secrets.SSH_PRIVATE_KEY + run: ssh -T git@github.com || echo "SSH key not authorized" - name: Checkout Code uses: actions/checkout@v4 with: @@ -29,6 +32,7 @@ jobs: ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} ssh-key: ${{ secrets.SSH_PRIVATE_KEY }} - - name: Show current Branch + + - name: Show current branch run: | git rev-parse --abbrev-ref HEAD \ No newline at end of file From 9ff6b0f54a216bbdddfde91b39f0dbb62bd9074d Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 18:21:15 +0200 Subject: [PATCH 009/117] Testing Build ENV --- .github/workflows/ci.yml | 29 ++++++++++++++++++++++++----- 1 file changed, 24 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5c5e4ebbad..d9a847c47b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,12 +19,9 @@ on: - dev jobs: - checkout_code: + checkout: runs-on: ubuntu-latest steps: - - name: Test SSH Key Authorization - if: secrets.SSH_PRIVATE_KEY - run: ssh -T git@github.com || echo "SSH key not authorized" - name: Checkout Code uses: actions/checkout@v4 with: @@ -35,4 +32,26 @@ jobs: - name: Show current branch run: | - git rev-parse --abbrev-ref HEAD \ No newline at end of file + git rev-parse --abbrev-ref HEAD + + build: + runs-on: ubuntu-latest + container: + image: amazoncorretto:17 + options: --user root + + steps: + # Install Gradle 8.10 + - name: Install Gradle 8.10 + run: | + GRADLE_VERSION=8.10 + wget https://services.gradle.org/distributions/gradle-${GRADLE_VERSION}-bin.zip -P /tmp + unzip /tmp/gradle-${GRADLE_VERSION}-bin.zip -d /opt/gradle + rm /tmp/gradle-${GRADLE_VERSION}-bin.zip + echo "export GRADLE_HOME=/opt/gradle/gradle-${GRADLE_VERSION}" >> $GITHUB_ENV + echo "export PATH=\$GRADLE_HOME/bin:\$PATH" >> $GITHUB_ENV + + # Verify Gradle and Java installation + - name: Verify Gradle & Java version + run: + gradle -v && java -v \ No newline at end of file From 7a63e640e1680750c092837d72d98096e46cd9a7 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 18:24:49 +0200 Subject: [PATCH 010/117] Added wget --- .github/workflows/ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d9a847c47b..348dc9b23f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -44,6 +44,8 @@ jobs: # Install Gradle 8.10 - name: Install Gradle 8.10 run: | + yum update -y + yum install -y wget unzip GRADLE_VERSION=8.10 wget https://services.gradle.org/distributions/gradle-${GRADLE_VERSION}-bin.zip -P /tmp unzip /tmp/gradle-${GRADLE_VERSION}-bin.zip -d /opt/gradle From 58b398b382624889a24ebbc4a7245e75d4584fb5 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 18:27:43 +0200 Subject: [PATCH 011/117] ENV --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 348dc9b23f..555ed69cb4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -50,8 +50,8 @@ jobs: wget https://services.gradle.org/distributions/gradle-${GRADLE_VERSION}-bin.zip -P /tmp unzip /tmp/gradle-${GRADLE_VERSION}-bin.zip -d /opt/gradle rm /tmp/gradle-${GRADLE_VERSION}-bin.zip - echo "export GRADLE_HOME=/opt/gradle/gradle-${GRADLE_VERSION}" >> $GITHUB_ENV - echo "export PATH=\$GRADLE_HOME/bin:\$PATH" >> $GITHUB_ENV + echo "GRADLE_HOME=/opt/gradle/gradle-${GRADLE_VERSION}" >> $GITHUB_ENV + echo "PATH=\$GRADLE_HOME/bin:\$PATH" >> $GITHUB_ENV # Verify Gradle and Java installation - name: Verify Gradle & Java version From 4907ebde12bec7aa74266d23146d973e43ca2515 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 18:29:56 +0200 Subject: [PATCH 012/117] added shell --- .github/workflows/ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 555ed69cb4..c87f90d197 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -43,6 +43,7 @@ jobs: steps: # Install Gradle 8.10 - name: Install Gradle 8.10 + shell: bash run: | yum update -y yum install -y wget unzip @@ -55,5 +56,6 @@ jobs: # Verify Gradle and Java installation - name: Verify Gradle & Java version + shell: bash run: gradle -v && java -v \ No newline at end of file From 717170db4a71dabbbf3d64c23c297f40fffa7f57 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 18:35:30 +0200 Subject: [PATCH 013/117] check java --- .github/workflows/ci.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c87f90d197..4b9a6325cf 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -43,7 +43,6 @@ jobs: steps: # Install Gradle 8.10 - name: Install Gradle 8.10 - shell: bash run: | yum update -y yum install -y wget unzip @@ -56,6 +55,5 @@ jobs: # Verify Gradle and Java installation - name: Verify Gradle & Java version - shell: bash run: - gradle -v && java -v \ No newline at end of file + java -v \ No newline at end of file From 868926f87bcdabb0e57d545a4e00752e6d1d9bff Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 18:40:23 +0200 Subject: [PATCH 014/117] check java --- .github/workflows/ci.yml | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4b9a6325cf..0314419580 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -43,17 +43,10 @@ jobs: steps: # Install Gradle 8.10 - name: Install Gradle 8.10 - run: | - yum update -y - yum install -y wget unzip - GRADLE_VERSION=8.10 - wget https://services.gradle.org/distributions/gradle-${GRADLE_VERSION}-bin.zip -P /tmp - unzip /tmp/gradle-${GRADLE_VERSION}-bin.zip -d /opt/gradle - rm /tmp/gradle-${GRADLE_VERSION}-bin.zip - echo "GRADLE_HOME=/opt/gradle/gradle-${GRADLE_VERSION}" >> $GITHUB_ENV - echo "PATH=\$GRADLE_HOME/bin:\$PATH" >> $GITHUB_ENV + run: + java -version # Verify Gradle and Java installation - name: Verify Gradle & Java version run: - java -v \ No newline at end of file + echo "test" \ No newline at end of file From 272364d4eace556d90b417bb50481f541f060dae Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 19:19:05 +0200 Subject: [PATCH 015/117] Created new Docker Image --- .github/workflows/ci.yml | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0314419580..d63d0d3e11 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -37,16 +37,11 @@ jobs: build: runs-on: ubuntu-latest container: - image: amazoncorretto:17 + image: morpheus99/corretto-gradle options: --user root steps: # Install Gradle 8.10 - - name: Install Gradle 8.10 + - name: Checking Gradle & Java run: - java -version - - # Verify Gradle and Java installation - - name: Verify Gradle & Java version - run: - echo "test" \ No newline at end of file + java -version && gradle --version \ No newline at end of file From c6f72b1f18fe4bf65b17a82f8752660d668e8956 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 19:42:34 +0200 Subject: [PATCH 016/117] Added Build and Test stage --- .github/workflows/ci.yml | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d63d0d3e11..6d9ceb9678 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -41,7 +41,31 @@ jobs: options: --user root steps: - # Install Gradle 8.10 - name: Checking Gradle & Java run: - java -version && gradle --version \ No newline at end of file + java -version && gradle --version + + - name: Building Project + run: + gradle clean assemble -p simona + + test: + runs-on: ubuntu-latest + container: + image: morpheus99/corretto-gradle + options: --user root + + steps: + - name: Checking Gradle & Java + run: + java -version && gradle --version + + - name: Running tests + run: + gradle --refresh-dependencies spotlessCheck pmdMain pmdTest -p simona + + - name: Generate JavaDoc + run: | + set +x + cd simona + ./gradlew javadoc \ No newline at end of file From 5d624e7fbe302eb784213269bfb00772279509c4 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 19:43:43 +0200 Subject: [PATCH 017/117] Fix --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6d9ceb9678..e2b31b73d1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -47,7 +47,7 @@ jobs: - name: Building Project run: - gradle clean assemble -p simona + gradle clean assemble test: runs-on: ubuntu-latest @@ -62,7 +62,7 @@ jobs: - name: Running tests run: - gradle --refresh-dependencies spotlessCheck pmdMain pmdTest -p simona + gradle --refresh-dependencies spotlessCheck pmdMain pmdTest - name: Generate JavaDoc run: | From cc50142e6d228b170ae89378721e74c0b33d20ad Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 19:47:03 +0200 Subject: [PATCH 018/117] Added right order --- .github/workflows/ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e2b31b73d1..9d614abbc6 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -35,6 +35,7 @@ jobs: git rev-parse --abbrev-ref HEAD build: + needs: checkout runs-on: ubuntu-latest container: image: morpheus99/corretto-gradle @@ -50,6 +51,7 @@ jobs: gradle clean assemble test: + needs: build runs-on: ubuntu-latest container: image: morpheus99/corretto-gradle From 9979cc8b1fc14080a6c9f57fba28f44521995b6e Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 19:58:52 +0200 Subject: [PATCH 019/117] Fix --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9d614abbc6..f6d621a766 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -47,6 +47,7 @@ jobs: java -version && gradle --version - name: Building Project + working-directory: simona run: gradle clean assemble From 82c04b5a59f7f2bf620ad378a9296abcbec136e5 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:00:42 +0200 Subject: [PATCH 020/117] Fix --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f6d621a766..471f72c055 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -33,6 +33,7 @@ jobs: - name: Show current branch run: | git rev-parse --abbrev-ref HEAD + pwd build: needs: checkout From 2f5d1edaf9fcdb35be1d0bb02d0b6417c5155dec Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:02:59 +0200 Subject: [PATCH 021/117] Fix --- .github/workflows/ci.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 471f72c055..e3bd48ed28 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -48,9 +48,10 @@ jobs: java -version && gradle --version - name: Building Project - working-directory: simona + working-directory: /__w/simona/simona run: - gradle clean assemble + pwd + sudo gradle clean assemble test: needs: build From 423824be7af3d24d43ff4c87a88ce9c1b0fe9f74 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:04:27 +0200 Subject: [PATCH 022/117] Fix --- .github/workflows/ci.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e3bd48ed28..3d1bbaffb7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -48,9 +48,10 @@ jobs: java -version && gradle --version - name: Building Project - working-directory: /__w/simona/simona + working-directory: /__w/simona run: pwd + ls sudo gradle clean assemble test: From de427e92fa6aad27f9b384998ff2fd33d251be61 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:05:20 +0200 Subject: [PATCH 023/117] Fix --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3d1bbaffb7..8036b28373 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -49,7 +49,7 @@ jobs: - name: Building Project working-directory: /__w/simona - run: + run: | pwd ls sudo gradle clean assemble From 480116702ab6e2f70c7efa8b854d0b12e105a72c Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:06:49 +0200 Subject: [PATCH 024/117] Fix --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8036b28373..38345bd8bd 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -48,11 +48,11 @@ jobs: java -version && gradle --version - name: Building Project - working-directory: /__w/simona + working-directory: /__w/simona/simona run: | pwd ls - sudo gradle clean assemble + gradle clean assemble test: needs: build From cc21a2e3c3dda37394ebf593a718a0bf46d06c0b Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:12:08 +0200 Subject: [PATCH 025/117] Fix --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 38345bd8bd..4ee872d076 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -34,6 +34,7 @@ jobs: run: | git rev-parse --abbrev-ref HEAD pwd + ls -la build: needs: checkout From 6ebc5e2a5568bfa18cd8e5f00adc040133459358 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:15:09 +0200 Subject: [PATCH 026/117] Added Volume --- .github/workflows/ci.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4ee872d076..262c6e81e4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -33,8 +33,6 @@ jobs: - name: Show current branch run: | git rev-parse --abbrev-ref HEAD - pwd - ls -la build: needs: checkout @@ -42,6 +40,8 @@ jobs: container: image: morpheus99/corretto-gradle options: --user root + volumes: + - /home/runner/work/${{ github.repository }}:/simona steps: - name: Checking Gradle & Java @@ -49,10 +49,10 @@ jobs: java -version && gradle --version - name: Building Project - working-directory: /__w/simona/simona + working-directory: /simona run: | pwd - ls + ls -la gradle clean assemble test: From 3434da4653c4d5a81d68802276c9ba712ee32249 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:18:23 +0200 Subject: [PATCH 027/117] Set clean to false --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 262c6e81e4..a6f46a777c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -26,6 +26,7 @@ jobs: uses: actions/checkout@v4 with: # Check if it's a pull request + clean: false ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} ssh-key: ${{ secrets.SSH_PRIVATE_KEY }} From 485d6c12dd7f7f0ffb82985223159c46cb1ddd6c Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:26:07 +0200 Subject: [PATCH 028/117] Set clean to true --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a6f46a777c..14d51c6220 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -26,14 +26,14 @@ jobs: uses: actions/checkout@v4 with: # Check if it's a pull request - clean: false ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} - ssh-key: ${{ secrets.SSH_PRIVATE_KEY }} - name: Show current branch run: | git rev-parse --abbrev-ref HEAD + pwd + ls -la build: needs: checkout From f136f27e3a4fea48824f494d00036bc530a6aa80 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:27:25 +0200 Subject: [PATCH 029/117] Fixed Volume Path --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 14d51c6220..22eac8688c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,7 +42,7 @@ jobs: image: morpheus99/corretto-gradle options: --user root volumes: - - /home/runner/work/${{ github.repository }}:/simona + - /home/runner/work/${{ github.repository }}/${{ github.repository }}:/simona steps: - name: Checking Gradle & Java From f0247713e441c7cd0b16f7864fd08d531984de1e Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:35:56 +0200 Subject: [PATCH 030/117] Fixed Volume Path --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 22eac8688c..4c6ed37e81 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,7 +42,7 @@ jobs: image: morpheus99/corretto-gradle options: --user root volumes: - - /home/runner/work/${{ github.repository }}/${{ github.repository }}:/simona + - /home/runner/work/simona/simona:/simona steps: - name: Checking Gradle & Java From ae3f4142384fb1f6d8d6e426ee17b5a6c2115450 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:39:11 +0200 Subject: [PATCH 031/117] Fixed Volume Path --- .github/workflows/ci.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4c6ed37e81..38bda5393d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -49,6 +49,11 @@ jobs: run: java -version && gradle --version + - name: Verify Files in Container + run: | + pwd + ls -la /simona + - name: Building Project working-directory: /simona run: | From cc00df1465017ed6fb4241159f7dff7835d03840 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:42:59 +0200 Subject: [PATCH 032/117] Fixed Volume Path --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 38bda5393d..b5644dab3f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -33,7 +33,7 @@ jobs: run: | git rev-parse --abbrev-ref HEAD pwd - ls -la + ls -la /home/runner/work/simona/simona build: needs: checkout @@ -42,7 +42,7 @@ jobs: image: morpheus99/corretto-gradle options: --user root volumes: - - /home/runner/work/simona/simona:/simona + - ${{ github.workspace }}:/simona steps: - name: Checking Gradle & Java From c892a8c4baacd12973d12ae64d77553b31c1da01 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:46:10 +0200 Subject: [PATCH 033/117] Fixed Volume Path --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b5644dab3f..3b52a7c2be 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -33,7 +33,7 @@ jobs: run: | git rev-parse --abbrev-ref HEAD pwd - ls -la /home/runner/work/simona/simona + ls -la ${{ github.workspace }} build: needs: checkout From 442d31b874feb7293a16a6f84d550e9cb43980c7 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 20:49:04 +0200 Subject: [PATCH 034/117] Fixed Volume Path --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3b52a7c2be..abd9f5005f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,7 +42,7 @@ jobs: image: morpheus99/corretto-gradle options: --user root volumes: - - ${{ github.workspace }}:/simona + - ${{ github.workspace }}:/simona:rw steps: - name: Checking Gradle & Java From 88b444784aa89201f7d723254a0ed93ceb5c2a14 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 21:49:46 +0200 Subject: [PATCH 035/117] Bind Volume --- .github/workflows/ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index abd9f5005f..a2cf74b22f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,7 +42,9 @@ jobs: image: morpheus99/corretto-gradle options: --user root volumes: - - ${{ github.workspace }}:/simona:rw + - type: bind + source: ${{ github.workspace }} + target: /simona steps: - name: Checking Gradle & Java From 26273ddbd74cc54e55a9b86688eb1d2ba1a54ab3 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 22:39:04 +0200 Subject: [PATCH 036/117] Fixed Docker Image --- .github/workflows/ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a2cf74b22f..3bc26d2759 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,9 +42,7 @@ jobs: image: morpheus99/corretto-gradle options: --user root volumes: - - type: bind - source: ${{ github.workspace }} - target: /simona + - ${{ github.workspace }}:/simona steps: - name: Checking Gradle & Java @@ -69,6 +67,8 @@ jobs: container: image: morpheus99/corretto-gradle options: --user root + volumes: + - ${{ github.workspace }}:/simona steps: - name: Checking Gradle & Java From b9016d1e5f95ee97255765a1b807c2ab687b9e5f Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 22:43:22 +0200 Subject: [PATCH 037/117] Fix --- .github/workflows/ci.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3bc26d2759..098d5b9309 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,13 +42,17 @@ jobs: image: morpheus99/corretto-gradle options: --user root volumes: - - ${{ github.workspace }}:/simona + - ${{ github.workspace }}:/simona:rw steps: - name: Checking Gradle & Java run: java -version && gradle --version + - name: Inspect Docker Mounts + run: + docker inspect $(docker ps -q) --format='{{json .Mounts}}' + - name: Verify Files in Container run: | pwd @@ -68,7 +72,7 @@ jobs: image: morpheus99/corretto-gradle options: --user root volumes: - - ${{ github.workspace }}:/simona + - ${{ github.workspace }}:/simona:rw steps: - name: Checking Gradle & Java From 07e14423b8ac10ed849995e1d8d4bd2d2b0442f1 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 22:58:05 +0200 Subject: [PATCH 038/117] Fix --- .github/workflows/ci.yml | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 098d5b9309..626efb46f8 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,17 +42,13 @@ jobs: image: morpheus99/corretto-gradle options: --user root volumes: - - ${{ github.workspace }}:/simona:rw + - ${{ github.workspace }}:/app:rw steps: - name: Checking Gradle & Java run: java -version && gradle --version - - name: Inspect Docker Mounts - run: - docker inspect $(docker ps -q) --format='{{json .Mounts}}' - - name: Verify Files in Container run: | pwd @@ -72,7 +68,7 @@ jobs: image: morpheus99/corretto-gradle options: --user root volumes: - - ${{ github.workspace }}:/simona:rw + - ${{ github.workspace }}:/app:rw steps: - name: Checking Gradle & Java From 16db60dcf64f099ddc68e1c284b75d01eee38b58 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 22:59:45 +0200 Subject: [PATCH 039/117] Fix --- .github/workflows/ci.yml | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 626efb46f8..95bab46ccc 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -49,13 +49,8 @@ jobs: run: java -version && gradle --version - - name: Verify Files in Container - run: | - pwd - ls -la /simona - - name: Building Project - working-directory: /simona + working-directory: /app run: | pwd ls -la From b21805d449f6b8dc913c3f908784f78b6ee7035c Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 23:02:09 +0200 Subject: [PATCH 040/117] Fix --- .github/workflows/ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 95bab46ccc..d7c174d3ff 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,7 +42,7 @@ jobs: image: morpheus99/corretto-gradle options: --user root volumes: - - ${{ github.workspace }}:/app:rw + - ${{ github.workspace }}:/simona:rw steps: - name: Checking Gradle & Java @@ -50,9 +50,9 @@ jobs: java -version && gradle --version - name: Building Project - working-directory: /app run: | pwd + cd /simona ls -la gradle clean assemble @@ -63,7 +63,7 @@ jobs: image: morpheus99/corretto-gradle options: --user root volumes: - - ${{ github.workspace }}:/app:rw + - ${{ github.workspace }}:/simona:rw steps: - name: Checking Gradle & Java From ddd5a92e5f0897a49513e4199d9926ac9687f995 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 23:07:07 +0200 Subject: [PATCH 041/117] Fix --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d7c174d3ff..643e128e2b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -39,7 +39,7 @@ jobs: needs: checkout runs-on: ubuntu-latest container: - image: morpheus99/corretto-gradle + image: gradle:8.10-jdk17 options: --user root volumes: - ${{ github.workspace }}:/simona:rw @@ -60,7 +60,7 @@ jobs: needs: build runs-on: ubuntu-latest container: - image: morpheus99/corretto-gradle + image: gradle:8.10-jdk17 options: --user root volumes: - ${{ github.workspace }}:/simona:rw From d9260e9e6af011debf752992e8ddc6dfc056f22e Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 23:08:36 +0200 Subject: [PATCH 042/117] Fix --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 643e128e2b..07fb29da32 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -53,6 +53,7 @@ jobs: run: | pwd cd /simona + pwd ls -la gradle clean assemble From bdd790617a756c7ca3d8168b1cfaf943e9156119 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 23:10:03 +0200 Subject: [PATCH 043/117] Fix --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 07fb29da32..573c73ef06 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -52,7 +52,7 @@ jobs: - name: Building Project run: | pwd - cd /simona + cd .. pwd ls -la gradle clean assemble From d537e09fe76f95e89bc3b56cefbc7b934848841a Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 23:11:18 +0200 Subject: [PATCH 044/117] Fix Volume --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 573c73ef06..ee97d09ea0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -52,6 +52,7 @@ jobs: - name: Building Project run: | pwd + ls -la cd .. pwd ls -la From 160bd9963fd9d17d006596ff3873ff9636023048 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 23:13:54 +0200 Subject: [PATCH 045/117] Fix Volume --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ee97d09ea0..3433674d1e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -65,7 +65,7 @@ jobs: image: gradle:8.10-jdk17 options: --user root volumes: - - ${{ github.workspace }}:/simona:rw + - ${{ github.workspace }}:/__w/simona/simona:rw steps: - name: Checking Gradle & Java From caafefe71464806dbcf6789f76e79d1f3ea7a200 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 23:14:48 +0200 Subject: [PATCH 046/117] Fix Volume --- .github/workflows/ci.yml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3433674d1e..6a17ce18df 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,7 +42,7 @@ jobs: image: gradle:8.10-jdk17 options: --user root volumes: - - ${{ github.workspace }}:/simona:rw + - ${{ github.workspace }}:/__w/simona/simona:rw steps: - name: Checking Gradle & Java @@ -51,9 +51,6 @@ jobs: - name: Building Project run: | - pwd - ls -la - cd .. pwd ls -la gradle clean assemble From f85defe4259e78030553292fd0bd5aa3c87c4f9a Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 23:20:52 +0200 Subject: [PATCH 047/117] Fix Volume --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6a17ce18df..adeb80f783 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -40,9 +40,8 @@ jobs: runs-on: ubuntu-latest container: image: gradle:8.10-jdk17 - options: --user root volumes: - - ${{ github.workspace }}:/__w/simona/simona:rw + - ${{ github.workspace }}:/simona:rw steps: - name: Checking Gradle & Java @@ -50,6 +49,7 @@ jobs: java -version && gradle --version - name: Building Project + working-directory: /simona run: | pwd ls -la From b7440c8ff715a72a537ad9a325ea69fd4504779b Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 23:24:07 +0200 Subject: [PATCH 048/117] Combined Checkout and Build --- .github/workflows/ci.yml | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index adeb80f783..b0c1395007 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,8 +19,14 @@ on: - dev jobs: - checkout: + + build: runs-on: ubuntu-latest + container: + image: gradle:8.10-jdk17 + volumes: + - ${{ github.workspace }}:/simona:rw + steps: - name: Checkout Code uses: actions/checkout@v4 @@ -29,25 +35,16 @@ jobs: ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} + - name: Checking Gradle & Java + run: + java -version && gradle --version + - name: Show current branch run: | git rev-parse --abbrev-ref HEAD pwd ls -la ${{ github.workspace }} - build: - needs: checkout - runs-on: ubuntu-latest - container: - image: gradle:8.10-jdk17 - volumes: - - ${{ github.workspace }}:/simona:rw - - steps: - - name: Checking Gradle & Java - run: - java -version && gradle --version - - name: Building Project working-directory: /simona run: | From c9f7e429283c12d17c393555e4c195553abfe0ce Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 23:25:46 +0200 Subject: [PATCH 049/117] Fix --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b0c1395007..33402b3280 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -41,6 +41,7 @@ jobs: - name: Show current branch run: | + git config --global --add safe.directory /__w/simona/simona git rev-parse --abbrev-ref HEAD pwd ls -la ${{ github.workspace }} From 68a7fc1c67699c120407043262290dee271b937f Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 23:40:45 +0200 Subject: [PATCH 050/117] Fix --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 33402b3280..e2e29ee933 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -44,7 +44,7 @@ jobs: git config --global --add safe.directory /__w/simona/simona git rev-parse --abbrev-ref HEAD pwd - ls -la ${{ github.workspace }} + ls -la /__w/simona/simona - name: Building Project working-directory: /simona From 9c53be5e75a04880dd1ae2b2ebab59cca8857a39 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 23:42:03 +0200 Subject: [PATCH 051/117] Fix Vol --- .github/workflows/ci.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e2e29ee933..4b326fe49b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -47,7 +47,6 @@ jobs: ls -la /__w/simona/simona - name: Building Project - working-directory: /simona run: | pwd ls -la From 0e57156ae57385e108d8bc033a6aa1ba5211505a Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Wed, 2 Oct 2024 23:56:21 +0200 Subject: [PATCH 052/117] Added Artifact --- .github/workflows/ci.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4b326fe49b..bd10045d3f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -52,6 +52,12 @@ jobs: ls -la gradle clean assemble + - name: Upload Build Artifact + uses: actions/upload-artifact@v3 + with: + name: simona-3.1.0-all.jar + path: ./build/libs + test: needs: build runs-on: ubuntu-latest @@ -66,6 +72,11 @@ jobs: run: java -version && gradle --version + - name: Download Build Artifact + uses: actions/download-artifact@v3 + with: + name: simona-3.1.0-all.jar + - name: Running tests run: gradle --refresh-dependencies spotlessCheck pmdMain pmdTest From b0b8a7dc8c028229a46a9fcb2980c38b654e8e18 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Thu, 3 Oct 2024 00:15:19 +0200 Subject: [PATCH 053/117] Added Artifact --- .github/workflows/ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bd10045d3f..08e24b5f5c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -45,6 +45,8 @@ jobs: git rev-parse --abbrev-ref HEAD pwd ls -la /__w/simona/simona + echo "__w" + ls -la /__w - name: Building Project run: | From 7f6a28104a389f8aa0fd4d9f2f0a92b8e344a89c Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Thu, 3 Oct 2024 00:20:00 +0200 Subject: [PATCH 054/117] Added Artifact --- .github/workflows/ci.yml | 35 +++++++++++++++++++++-------------- 1 file changed, 21 insertions(+), 14 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 08e24b5f5c..bf92557e6c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,6 +19,22 @@ on: - dev jobs: + checkout: + runs-on: ubuntu-latest + + steps: + - name: Checkout Code + uses: actions/checkout@v4 + with: + # Check if it's a pull request + ref: ${{ github.event.pull_request.head.ref || github.ref }} + repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} + + - name: Show current branch + run: | + git rev-parse --abbrev-ref HEAD + pwd + ls -la build: runs-on: ubuntu-latest @@ -28,26 +44,17 @@ jobs: - ${{ github.workspace }}:/simona:rw steps: - - name: Checkout Code - uses: actions/checkout@v4 - with: - # Check if it's a pull request - ref: ${{ github.event.pull_request.head.ref || github.ref }} - repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} - - - name: Checking Gradle & Java - run: - java -version && gradle --version - - - name: Show current branch + - name: Dir Check run: | - git config --global --add safe.directory /__w/simona/simona - git rev-parse --abbrev-ref HEAD pwd ls -la /__w/simona/simona echo "__w" ls -la /__w + - name: Checking Gradle & Java + run: + java -version && gradle --version + - name: Building Project run: | pwd From c14c0a6b4b7b05ebb6606d6eb7f0acdd68116a4d Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Thu, 3 Oct 2024 00:23:23 +0200 Subject: [PATCH 055/117] Fix syntax --- .github/workflows/ci.yml | 38 ++++++++++++++++---------------------- 1 file changed, 16 insertions(+), 22 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bf92557e6c..ce00584631 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -22,19 +22,19 @@ jobs: checkout: runs-on: ubuntu-latest - steps: - - name: Checkout Code - uses: actions/checkout@v4 - with: - # Check if it's a pull request - ref: ${{ github.event.pull_request.head.ref || github.ref }} - repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} + steps: + - name: Checkout Code + uses: actions/checkout@v4 + with: + # Check if it's a pull request + ref: ${{ github.event.pull_request.head.ref || github.ref }} + repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} - - name: Show current branch - run: | - git rev-parse --abbrev-ref HEAD - pwd - ls -la + - name: Show current branch + run: | + git rev-parse --abbrev-ref HEAD + pwd + ls -la build: runs-on: ubuntu-latest @@ -52,7 +52,7 @@ jobs: ls -la /__w - name: Checking Gradle & Java - run: + run: | java -version && gradle --version - name: Building Project @@ -61,12 +61,6 @@ jobs: ls -la gradle clean assemble - - name: Upload Build Artifact - uses: actions/upload-artifact@v3 - with: - name: simona-3.1.0-all.jar - path: ./build/libs - test: needs: build runs-on: ubuntu-latest @@ -78,7 +72,7 @@ jobs: steps: - name: Checking Gradle & Java - run: + run: | java -version && gradle --version - name: Download Build Artifact @@ -87,11 +81,11 @@ jobs: name: simona-3.1.0-all.jar - name: Running tests - run: + run: | gradle --refresh-dependencies spotlessCheck pmdMain pmdTest - name: Generate JavaDoc run: | set +x cd simona - ./gradlew javadoc \ No newline at end of file + ./gradlew javadoc From 4b3e51c446bbdf440ddd26cd5c6594c210818e08 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Thu, 3 Oct 2024 00:25:30 +0200 Subject: [PATCH 056/117] Debug --- .github/workflows/ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ce00584631..b291fb1964 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -37,6 +37,7 @@ jobs: ls -la build: + needs: checkout runs-on: ubuntu-latest container: image: gradle:8.10-jdk17 @@ -50,6 +51,8 @@ jobs: ls -la /__w/simona/simona echo "__w" ls -la /__w + echo "__w/_temp" + ls -la /__w/_temp - name: Checking Gradle & Java run: | From 99a876e8cd0f3980e874f8e0a10ef6be18a0b18c Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Thu, 3 Oct 2024 00:32:48 +0200 Subject: [PATCH 057/117] Debug --- .github/workflows/ci.yml | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b291fb1964..9e2e89ba8c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -36,6 +36,30 @@ jobs: pwd ls -la + test-mount: + runs-on: ubuntu-latest + + steps: + # 1. Code Checkout auf dem Host (ohne Container) + - name: Checkout Code + uses: actions/checkout@v4 + + # 2. Überprüfung des Verzeichnisses auf dem Host nach dem Checkout + - name: Verify Files on Host after Checkout + run: | + echo "Verzeichnis auf dem Host:" + ls -la ${{ github.workspace }} + + # 3. Container-Schritt zum Testen des Mounts + - name: Verify Mount in Container + container: + image: ubuntu:latest # Verwende ein einfaches Image zum Testen + volumes: + - ${{ github.workspace }}:/simona:rw + run: | + echo "Verzeichnis im Container:" + ls -la /simona + build: needs: checkout runs-on: ubuntu-latest From 50979d2658c816da566524e7601e6bddfa87317a Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Thu, 3 Oct 2024 00:33:59 +0200 Subject: [PATCH 058/117] Debug --- .github/workflows/ci.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9e2e89ba8c..4d0d4df263 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -37,6 +37,7 @@ jobs: ls -la test-mount: + needs: checkout runs-on: ubuntu-latest steps: @@ -61,7 +62,7 @@ jobs: ls -la /simona build: - needs: checkout + needs: test-mount runs-on: ubuntu-latest container: image: gradle:8.10-jdk17 From 7aa55ba7fbda6e0614d04c218af973a7fb275900 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Thu, 3 Oct 2024 00:35:26 +0200 Subject: [PATCH 059/117] STOP --- .github/workflows/ci.yml | 25 ------------------------- 1 file changed, 25 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4d0d4df263..dc3abbd2de 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -36,31 +36,6 @@ jobs: pwd ls -la - test-mount: - needs: checkout - runs-on: ubuntu-latest - - steps: - # 1. Code Checkout auf dem Host (ohne Container) - - name: Checkout Code - uses: actions/checkout@v4 - - # 2. Überprüfung des Verzeichnisses auf dem Host nach dem Checkout - - name: Verify Files on Host after Checkout - run: | - echo "Verzeichnis auf dem Host:" - ls -la ${{ github.workspace }} - - # 3. Container-Schritt zum Testen des Mounts - - name: Verify Mount in Container - container: - image: ubuntu:latest # Verwende ein einfaches Image zum Testen - volumes: - - ${{ github.workspace }}:/simona:rw - run: | - echo "Verzeichnis im Container:" - ls -la /simona - build: needs: test-mount runs-on: ubuntu-latest From 25346e65dec31618c247ded3cab541ea3c2080be Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Thu, 3 Oct 2024 00:47:57 +0200 Subject: [PATCH 060/117] test --- .github/workflows/ci.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index dc3abbd2de..5077ab37de 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -37,7 +37,7 @@ jobs: ls -la build: - needs: test-mount + needs: checkout runs-on: ubuntu-latest container: image: gradle:8.10-jdk17 @@ -47,6 +47,8 @@ jobs: steps: - name: Dir Check run: | + echo "${{ github.workspace }}" + echo "$GITHUB_WORKSPACE" pwd ls -la /__w/simona/simona echo "__w" @@ -71,7 +73,7 @@ jobs: image: gradle:8.10-jdk17 options: --user root volumes: - - ${{ github.workspace }}:/__w/simona/simona:rw + - ${{ github.workspace }}:/simona:rw steps: - name: Checking Gradle & Java From 8c4b71b1aadaf0141b2632d791fdfda92bea4e39 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Thu, 3 Oct 2024 00:53:20 +0200 Subject: [PATCH 061/117] Volume --- .github/workflows/ci.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5077ab37de..a37cbc5dca 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,13 +42,11 @@ jobs: container: image: gradle:8.10-jdk17 volumes: - - ${{ github.workspace }}:/simona:rw + - /home/runner/work/simona/simona:/simona:rw steps: - name: Dir Check run: | - echo "${{ github.workspace }}" - echo "$GITHUB_WORKSPACE" pwd ls -la /__w/simona/simona echo "__w" @@ -61,6 +59,7 @@ jobs: java -version && gradle --version - name: Building Project + working-directory: /simona run: | pwd ls -la From 517d9e5c49313851632020c26c81eca92cad7af0 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Thu, 3 Oct 2024 15:00:41 +0200 Subject: [PATCH 062/117] Using Cache --- .github/workflows/ci.yml | 26 ++++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a37cbc5dca..6632558211 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -30,36 +30,38 @@ jobs: ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} - - name: Show current branch + - name: Check Branch & Files run: | git rev-parse --abbrev-ref HEAD pwd ls -la + - name: Cache project files + uses: actions/cache@v3 + with: + path: | + . + key: ${{ runner.os }}-project-${{ github.sha }} + build: needs: checkout runs-on: ubuntu-latest container: image: gradle:8.10-jdk17 - volumes: - - /home/runner/work/simona/simona:/simona:rw steps: - - name: Dir Check - run: | - pwd - ls -la /__w/simona/simona - echo "__w" - ls -la /__w - echo "__w/_temp" - ls -la /__w/_temp + - name: Restore project files + uses: actions/cache@v3 + with: + path: | + . + key: ${{ runner.os }}-project-${{ github.sha }} - name: Checking Gradle & Java run: | java -version && gradle --version - name: Building Project - working-directory: /simona run: | pwd ls -la From f58d317c5ad176d9bc90f577abd87a7e441ebce8 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Fri, 4 Oct 2024 15:11:07 +0200 Subject: [PATCH 063/117] Cache Fix --- .github/workflows/ci.yml | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6632558211..f597ba3c68 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -37,10 +37,10 @@ jobs: ls -la - name: Cache project files - uses: actions/cache@v3 + uses: actions/cache/save@v4 + id: cache with: - path: | - . + path: . key: ${{ runner.os }}-project-${{ github.sha }} build: @@ -51,11 +51,10 @@ jobs: steps: - name: Restore project files - uses: actions/cache@v3 + uses: actions/cache/restore@v4 + id: restore-cache with: - path: | - . - key: ${{ runner.os }}-project-${{ github.sha }} + key: ${{ runner.os }}-project-${{ github.sha }} - name: Checking Gradle & Java run: | From f11304039fa37561b69e88bb432a9ad3487cd168 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Fri, 4 Oct 2024 15:14:00 +0200 Subject: [PATCH 064/117] Cache Fix --- .github/workflows/ci.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f597ba3c68..2bc6c140e2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -40,7 +40,7 @@ jobs: uses: actions/cache/save@v4 id: cache with: - path: . + path: ./ key: ${{ runner.os }}-project-${{ github.sha }} build: @@ -54,6 +54,7 @@ jobs: uses: actions/cache/restore@v4 id: restore-cache with: + path: ./ key: ${{ runner.os }}-project-${{ github.sha }} - name: Checking Gradle & Java From 62656dbab490a14b849c292a9c752febcf53e5cf Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Fri, 4 Oct 2024 15:26:51 +0200 Subject: [PATCH 065/117] Cache Fix --- .github/workflows/ci.yml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2bc6c140e2..9ea6c47ae1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,6 +5,10 @@ name: CI +#Variables +env: + CHECKOUT_SHA: "" + on: push: branches: @@ -41,7 +45,10 @@ jobs: id: cache with: path: ./ - key: ${{ runner.os }}-project-${{ github.sha }} + key: simona-${{ github.sha }} + run: | + echo "COMMIT_SHA=${GITHUB_SHA}" >> $GITHUB_ENV + echo "${{ github.sha }}" build: needs: checkout From 8999526ee0d51c12dd364d22270a6e26600ec480 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Fri, 4 Oct 2024 15:30:48 +0200 Subject: [PATCH 066/117] Cache Fix --- .github/workflows/ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9ea6c47ae1..703eaab3fe 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -46,6 +46,8 @@ jobs: with: path: ./ key: simona-${{ github.sha }} + + - name: Print run: | echo "COMMIT_SHA=${GITHUB_SHA}" >> $GITHUB_ENV echo "${{ github.sha }}" From 21835f8f97cb91ed7c1c47ad3a3046c9461a3145 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Fri, 4 Oct 2024 15:32:43 +0200 Subject: [PATCH 067/117] Cache Fix --- .github/workflows/ci.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 703eaab3fe..bfc4c3f48b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -47,7 +47,7 @@ jobs: path: ./ key: simona-${{ github.sha }} - - name: Print + - name: Save Commit SHA run: | echo "COMMIT_SHA=${GITHUB_SHA}" >> $GITHUB_ENV echo "${{ github.sha }}" @@ -59,12 +59,15 @@ jobs: image: gradle:8.10-jdk17 steps: + - name: Print SHA + run: echo "${{ github.sha }}" + - name: Restore project files uses: actions/cache/restore@v4 id: restore-cache with: path: ./ - key: ${{ runner.os }}-project-${{ github.sha }} + key: simona-${{ github.sha }} - name: Checking Gradle & Java run: | From 47dc2b26d30b55a8f8109760f55a36f25e1f0950 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Fri, 4 Oct 2024 15:41:16 +0200 Subject: [PATCH 068/117] Cache Fix --- .github/workflows/ci.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bfc4c3f48b..bc2680d072 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -41,10 +41,11 @@ jobs: ls -la - name: Cache project files - uses: actions/cache/save@v4 + uses: actions/cache@v3 id: cache with: - path: ./ + path: | + . #Cache all files key: simona-${{ github.sha }} - name: Save Commit SHA From f623598e4880d47839624c1c3e9fc2540dbad432 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Fri, 4 Oct 2024 15:42:25 +0200 Subject: [PATCH 069/117] Cache Fix --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bc2680d072..22f25debdd 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -41,11 +41,11 @@ jobs: ls -la - name: Cache project files - uses: actions/cache@v3 + uses: actions/cache/save@v4 id: cache with: path: | - . #Cache all files + . key: simona-${{ github.sha }} - name: Save Commit SHA From a6ee5865276a5bb783215150069b01756781a49a Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Fri, 4 Oct 2024 15:46:48 +0200 Subject: [PATCH 070/117] Cache Fix --- .github/workflows/ci.yml | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 22f25debdd..92a9378bff 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -41,11 +41,9 @@ jobs: ls -la - name: Cache project files - uses: actions/cache/save@v4 - id: cache + uses: actions/cache@v3 with: - path: | - . + path: ./ key: simona-${{ github.sha }} - name: Save Commit SHA @@ -64,8 +62,7 @@ jobs: run: echo "${{ github.sha }}" - name: Restore project files - uses: actions/cache/restore@v4 - id: restore-cache + uses: actions/cache@v3 with: path: ./ key: simona-${{ github.sha }} From fed2642a7630a727ef6e6e356c24ce2c35b30579 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Fri, 4 Oct 2024 15:53:30 +0200 Subject: [PATCH 071/117] Cache Fix --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 92a9378bff..5b7ec1e4bc 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -44,7 +44,7 @@ jobs: uses: actions/cache@v3 with: path: ./ - key: simona-${{ github.sha }} + key: simona - name: Save Commit SHA run: | @@ -65,7 +65,7 @@ jobs: uses: actions/cache@v3 with: path: ./ - key: simona-${{ github.sha }} + key: simona - name: Checking Gradle & Java run: | From c0b408bf47444d2e3c19e61fb3bc57ac21069c23 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Fri, 4 Oct 2024 15:57:14 +0200 Subject: [PATCH 072/117] Cache Fix --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5b7ec1e4bc..6c07dbcb8d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -46,6 +46,7 @@ jobs: path: ./ key: simona + # - name: Save Commit SHA run: | echo "COMMIT_SHA=${GITHUB_SHA}" >> $GITHUB_ENV From 51a29b8e178577bedc98303b2977c95a2192813e Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Fri, 4 Oct 2024 16:03:33 +0200 Subject: [PATCH 073/117] Using artifacts --- .github/workflows/ci.yml | 21 ++++++--------------- 1 file changed, 6 insertions(+), 15 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6c07dbcb8d..7ffe52b1a5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -40,17 +40,11 @@ jobs: pwd ls -la - - name: Cache project files - uses: actions/cache@v3 + - name: Upload build directory as artifact + uses: actions/upload-artifact@v3 with: + name: project-files path: ./ - key: simona - - # - - name: Save Commit SHA - run: | - echo "COMMIT_SHA=${GITHUB_SHA}" >> $GITHUB_ENV - echo "${{ github.sha }}" build: needs: checkout @@ -59,14 +53,11 @@ jobs: image: gradle:8.10-jdk17 steps: - - name: Print SHA - run: echo "${{ github.sha }}" - - - name: Restore project files - uses: actions/cache@v3 + - name: Download project-files + uses: actions/download-artifact@v3 with: + name: project-files path: ./ - key: simona - name: Checking Gradle & Java run: | From a7d508d0ac06ef9fac847c5b17711327f8934282 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Fri, 4 Oct 2024 16:32:26 +0200 Subject: [PATCH 074/117] Changed approach in passing files --- .github/workflows/ci.yml | 42 +++++++++++++++------------------------- 1 file changed, 16 insertions(+), 26 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7ffe52b1a5..db6a23e683 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -23,8 +23,11 @@ on: - dev jobs: - checkout: + + build: runs-on: ubuntu-latest + container: + image: gradle:8.10-jdk17 steps: - name: Checkout Code @@ -40,43 +43,30 @@ jobs: pwd ls -la - - name: Upload build directory as artifact - uses: actions/upload-artifact@v3 - with: - name: project-files - path: ./ - - build: - needs: checkout - runs-on: ubuntu-latest - container: - image: gradle:8.10-jdk17 - - steps: - - name: Download project-files - uses: actions/download-artifact@v3 - with: - name: project-files - path: ./ - - name: Checking Gradle & Java run: | java -version && gradle --version - name: Building Project run: | - pwd - ls -la gradle clean assemble + - name: Upload Artifact + uses: actions/upload-artifact@v3 + with: + name: simona-build + path: | + build/ # Der gesamte 'build'-Ordner + build.gradle # Haupt-Gradle-Datei + settings.gradle # Projekt- und Modulkonfiguration + gradle/wrapper/ # Gradle-Wrapper-Dateien + .gradle/ # Cache-Dateien von Gradle (optional) + test: needs: build runs-on: ubuntu-latest container: image: gradle:8.10-jdk17 - options: --user root - volumes: - - ${{ github.workspace }}:/simona:rw steps: - name: Checking Gradle & Java @@ -86,7 +76,7 @@ jobs: - name: Download Build Artifact uses: actions/download-artifact@v3 with: - name: simona-3.1.0-all.jar + name: simona-build - name: Running tests run: | From 9a84f3e97a4485fa5166625c1e3f849f16cf02b9 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Fri, 4 Oct 2024 16:33:27 +0200 Subject: [PATCH 075/117] Changed approach in passing files --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index db6a23e683..1987ab199b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -39,6 +39,7 @@ jobs: - name: Check Branch & Files run: | + git config --global --add safe.directory /__w/simona/simona git rev-parse --abbrev-ref HEAD pwd ls -la From 26d977fdc1b30e81a356f8eceb76cdaa31942aa6 Mon Sep 17 00:00:00 2001 From: Philipp Schmelter Date: Fri, 4 Oct 2024 16:38:01 +0200 Subject: [PATCH 076/117] Debug --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1987ab199b..73c4179396 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -51,6 +51,7 @@ jobs: - name: Building Project run: | gradle clean assemble + ls -la - name: Upload Artifact uses: actions/upload-artifact@v3 From 5aa9679e9c9e27184726d9cacc3d7105718fa1c5 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Mon, 7 Oct 2024 19:56:29 +0200 Subject: [PATCH 077/117] Fixed Path --- .github/workflows/ci.yml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 73c4179396..7a43aaa9e6 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,10 +5,6 @@ name: CI -#Variables -env: - CHECKOUT_SHA: "" - on: push: branches: @@ -58,7 +54,7 @@ jobs: with: name: simona-build path: | - build/ # Der gesamte 'build'-Ordner + ./build/** # Der gesamte 'build'-Ordner build.gradle # Haupt-Gradle-Datei settings.gradle # Projekt- und Modulkonfiguration gradle/wrapper/ # Gradle-Wrapper-Dateien From da5336ba5a968d4592929c4a5c7857ef76cc0d4d Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Mon, 7 Oct 2024 20:01:01 +0200 Subject: [PATCH 078/117] Fixed Path --- .github/workflows/ci.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7a43aaa9e6..a4a02d784b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -54,11 +54,11 @@ jobs: with: name: simona-build path: | - ./build/** # Der gesamte 'build'-Ordner - build.gradle # Haupt-Gradle-Datei - settings.gradle # Projekt- und Modulkonfiguration - gradle/wrapper/ # Gradle-Wrapper-Dateien - .gradle/ # Cache-Dateien von Gradle (optional) + ./build/** + build.gradle + settings.gradle + gradle/wrapper/ + .gradle/ test: needs: build From 8da5343184e5ac39ac6b2d5a387710ce2148a702 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Mon, 7 Oct 2024 20:15:21 +0200 Subject: [PATCH 079/117] Fixed Path --- .github/workflows/ci.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a4a02d784b..e6acaf4597 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -54,11 +54,13 @@ jobs: with: name: simona-build path: | - ./build/** + ./build/classes/** + ./build/resources/** + ./build/libs/** + gradle/wrapper/** + gradlew build.gradle settings.gradle - gradle/wrapper/ - .gradle/ test: needs: build From 4b65e113d72f93812d52b7897e580d6c26bd737a Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Mon, 7 Oct 2024 20:16:00 +0200 Subject: [PATCH 080/117] Fixed Path --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e6acaf4597..7362ddd4d6 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -58,6 +58,7 @@ jobs: ./build/resources/** ./build/libs/** gradle/wrapper/** + gradle/scripts/** gradlew build.gradle settings.gradle From 5ec36de4b305db54621f862b207f7d086690fdfd Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Mon, 7 Oct 2024 20:22:44 +0200 Subject: [PATCH 081/117] Fixed Path --- .github/workflows/ci.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7362ddd4d6..94d4769474 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -54,9 +54,7 @@ jobs: with: name: simona-build path: | - ./build/classes/** - ./build/resources/** - ./build/libs/** + ./build/** gradle/wrapper/** gradle/scripts/** gradlew From fc39fbbbad4de6cbde19fae554027d4d6a91b69d Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Tue, 8 Oct 2024 15:15:06 +0200 Subject: [PATCH 082/117] Caching Gradle Dependencies --- .github/workflows/ci.yml | 27 +++++++++++++++++++++++++-- 1 file changed, 25 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 94d4769474..d72139d58a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -33,6 +33,16 @@ jobs: ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} + - name: Cache Gradle dependencies + uses: actions/cache@v3 + with: + path: | + ~/.gradle/caches + ~/.gradle/wrapper + key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} + restore-keys: | + ${{ runner.os }}-gradle + - name: Check Branch & Files run: | git config --global --add safe.directory /__w/simona/simona @@ -54,7 +64,9 @@ jobs: with: name: simona-build path: | - ./build/** + ./build/classes/** + ./build/resources/test/** + ./build/libs/** gradle/wrapper/** gradle/scripts/** gradlew @@ -68,6 +80,16 @@ jobs: image: gradle:8.10-jdk17 steps: + - name: Cache Gradle dependencies + uses: actions/cache@v3 + with: + path: | + ~/.gradle/caches + ~/.gradle/wrapper + key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} + restore-keys: | + ${{ runner.os }}-gradle + - name: Checking Gradle & Java run: | java -version && gradle --version @@ -78,8 +100,9 @@ jobs: name: simona-build - name: Running tests + working-directory: ./simona run: | - gradle --refresh-dependencies spotlessCheck pmdMain pmdTest + gradle --no-daemon --info --refresh-dependencies spotlessCheck pmdMain pmdTest - name: Generate JavaDoc run: | From e279c01121da8117f243e7caeab5580eec12ce3b Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Tue, 8 Oct 2024 15:21:29 +0200 Subject: [PATCH 083/117] Removed workdir --- .github/workflows/ci.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d72139d58a..da7e5a65ee 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -100,7 +100,6 @@ jobs: name: simona-build - name: Running tests - working-directory: ./simona run: | gradle --no-daemon --info --refresh-dependencies spotlessCheck pmdMain pmdTest From 5044de6a64fb8cb909c4254ad7b12122d034e3a5 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Tue, 8 Oct 2024 15:40:57 +0200 Subject: [PATCH 084/117] Fixes --- .github/workflows/ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index da7e5a65ee..60d29f1e70 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -33,7 +33,7 @@ jobs: ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} - - name: Cache Gradle dependencies + - name: Cache Gradle packages uses: actions/cache@v3 with: path: | @@ -41,7 +41,7 @@ jobs: ~/.gradle/wrapper key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} restore-keys: | - ${{ runner.os }}-gradle + ${{ runner.os }}-gradle- - name: Check Branch & Files run: | @@ -56,7 +56,7 @@ jobs: - name: Building Project run: | - gradle clean assemble + ./gradlew clean assemble ls -la - name: Upload Artifact From 711beaea3b57f27fed94a6b7826b22f5a752f7ab Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Tue, 8 Oct 2024 15:45:05 +0200 Subject: [PATCH 085/117] Fixes --- .github/workflows/ci.yml | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 60d29f1e70..c778e2f508 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -33,16 +33,6 @@ jobs: ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} - - name: Cache Gradle packages - uses: actions/cache@v3 - with: - path: | - ~/.gradle/caches - ~/.gradle/wrapper - key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} - restore-keys: | - ${{ runner.os }}-gradle- - - name: Check Branch & Files run: | git config --global --add safe.directory /__w/simona/simona @@ -59,6 +49,16 @@ jobs: ./gradlew clean assemble ls -la + - name: Cache Gradle packages + uses: actions/cache@v3 + with: + path: | + ~/.gradle/caches + ~/.gradle/wrapper + key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} + restore-keys: | + ${{ runner.os }}-gradle- + - name: Upload Artifact uses: actions/upload-artifact@v3 with: @@ -80,7 +80,7 @@ jobs: image: gradle:8.10-jdk17 steps: - - name: Cache Gradle dependencies + - name: Cache Gradle packages uses: actions/cache@v3 with: path: | @@ -88,7 +88,7 @@ jobs: ~/.gradle/wrapper key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} restore-keys: | - ${{ runner.os }}-gradle + ${{ runner.os }}-gradle- - name: Checking Gradle & Java run: | From 1d0ba091142a012ad6b06adfcc5e445b2d62031b Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Tue, 8 Oct 2024 16:06:43 +0200 Subject: [PATCH 086/117] Removed Artifacting Trying Cache --- .github/workflows/ci.yml | 52 ++++++++++++++-------------------------- 1 file changed, 18 insertions(+), 34 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c778e2f508..b305f0fd68 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,7 +29,6 @@ jobs: - name: Checkout Code uses: actions/checkout@v4 with: - # Check if it's a pull request ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} @@ -49,62 +48,47 @@ jobs: ./gradlew clean assemble ls -la - - name: Cache Gradle packages + - name: Cache Gradle Wrapper and Build Files uses: actions/cache@v3 with: path: | - ~/.gradle/caches - ~/.gradle/wrapper + ./build/ + ./gradle/ key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} restore-keys: | ${{ runner.os }}-gradle- - - name: Upload Artifact - uses: actions/upload-artifact@v3 - with: - name: simona-build - path: | - ./build/classes/** - ./build/resources/test/** - ./build/libs/** - gradle/wrapper/** - gradle/scripts/** - gradlew - build.gradle - settings.gradle - test: needs: build runs-on: ubuntu-latest container: image: gradle:8.10-jdk17 + services: + docker: + image: docker:19.03.12 + options: --privileged steps: - - name: Cache Gradle packages + - name: Checkout Code + uses: actions/checkout@v4 + with: + ref: ${{ github.event.pull_request.head.ref || github.ref }} + repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} + + - name: Cache Gradle Wrapper and Build Files uses: actions/cache@v3 with: path: | - ~/.gradle/caches - ~/.gradle/wrapper + ./build/ + ./gradle/wrapper/ key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} restore-keys: | ${{ runner.os }}-gradle- - - name: Checking Gradle & Java - run: | - java -version && gradle --version - - - name: Download Build Artifact - uses: actions/download-artifact@v3 - with: - name: simona-build - - - name: Running tests + - name: Running Tests run: | - gradle --no-daemon --info --refresh-dependencies spotlessCheck pmdMain pmdTest + ./gradlew --no-daemon --info --refresh-dependencies spotlessCheck pmdMain pmdTest test - name: Generate JavaDoc run: | - set +x - cd simona ./gradlew javadoc From f703367a5ab171420595717bd19ab5bc38bf26cf Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Tue, 8 Oct 2024 16:31:15 +0200 Subject: [PATCH 087/117] Seperated Build Artifact and Gradle Cache --- .github/workflows/ci.yml | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b305f0fd68..2ccbad0c76 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -48,16 +48,21 @@ jobs: ./gradlew clean assemble ls -la - - name: Cache Gradle Wrapper and Build Files + - name: Cache Gradle uses: actions/cache@v3 with: path: | - ./build/ ./gradle/ key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} restore-keys: | ${{ runner.os }}-gradle- + - name: Upload Build Artifacts + uses: actions/upload-artifact@v3 + with: + name: build-artifacts + path: ./build/ + test: needs: build runs-on: ubuntu-latest @@ -75,12 +80,11 @@ jobs: ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} - - name: Cache Gradle Wrapper and Build Files + - name: Download Gradle Cache uses: actions/cache@v3 with: path: | - ./build/ - ./gradle/wrapper/ + ./gradle/ key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} restore-keys: | ${{ runner.os }}-gradle- From d060f807ae9add4a21f4b761f11e5673d5ec2f0b Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Tue, 8 Oct 2024 16:45:55 +0200 Subject: [PATCH 088/117] All jobs in one stage test --- .github/workflows/ci.yml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2ccbad0c76..3d983fc348 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -45,9 +45,17 @@ jobs: - name: Building Project run: | - ./gradlew clean assemble + ./gradle clean assemble ls -la + - name: Running Tests + run: | + ./gradle --no-daemon --info --refresh-dependencies spotlessCheck pmdMain pmdTest test + + - name: Generate JavaDoc + run: | + ./gradlew javadoc + - name: Cache Gradle uses: actions/cache@v3 with: From 7eab7867083ef684e5d8c551324034ebedf6085a Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Tue, 8 Oct 2024 16:52:16 +0200 Subject: [PATCH 089/117] Fixed permissions --- .github/workflows/ci.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3d983fc348..5e61feaf49 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -45,12 +45,13 @@ jobs: - name: Building Project run: | - ./gradle clean assemble + chmod +x ./gradlew + ./gradlew clean assemble ls -la - name: Running Tests run: | - ./gradle --no-daemon --info --refresh-dependencies spotlessCheck pmdMain pmdTest test + ./gradlew --no-daemon --info --refresh-dependencies spotlessCheck pmdMain pmdTest test - name: Generate JavaDoc run: | From cee3934528b210925063dda17070d119fb0e38a3 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Tue, 8 Oct 2024 18:39:23 +0200 Subject: [PATCH 090/117] Test --- .github/workflows/ci.yml | 6 ------ 1 file changed, 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5e61feaf49..e7b72de7d4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -43,12 +43,6 @@ jobs: run: | java -version && gradle --version - - name: Building Project - run: | - chmod +x ./gradlew - ./gradlew clean assemble - ls -la - - name: Running Tests run: | ./gradlew --no-daemon --info --refresh-dependencies spotlessCheck pmdMain pmdTest test From 54dce131b80e513986aed07f14463ec3d8249d8a Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Tue, 8 Oct 2024 18:40:14 +0200 Subject: [PATCH 091/117] Test --- .github/workflows/ci.yml | 23 ----------------------- 1 file changed, 23 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e7b72de7d4..d5e0563a7b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -51,21 +51,6 @@ jobs: run: | ./gradlew javadoc - - name: Cache Gradle - uses: actions/cache@v3 - with: - path: | - ./gradle/ - key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} - restore-keys: | - ${{ runner.os }}-gradle- - - - name: Upload Build Artifacts - uses: actions/upload-artifact@v3 - with: - name: build-artifacts - path: ./build/ - test: needs: build runs-on: ubuntu-latest @@ -83,14 +68,6 @@ jobs: ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} - - name: Download Gradle Cache - uses: actions/cache@v3 - with: - path: | - ./gradle/ - key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} - restore-keys: | - ${{ runner.os }}-gradle- - name: Running Tests run: | From c96acf7345c3c98b45132991dadba459bc58ea07 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Tue, 8 Oct 2024 18:51:21 +0200 Subject: [PATCH 092/117] Test --- .github/workflows/ci.yml | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d5e0563a7b..e1870f98a4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -45,12 +45,28 @@ jobs: - name: Running Tests run: | - ./gradlew --no-daemon --info --refresh-dependencies spotlessCheck pmdMain pmdTest test + ./gradlew --no-daemon --info --refresh-dependencies spotlessCheck pmdMain pmdTest test -x build -x compileJava -x compileTestJava -x assemble + - name: Generate JavaDoc run: | ./gradlew javadoc + - name: Cache Gradle + uses: actions/cache@v3 + with: + path: | + ./gradle/ + key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} + restore-keys: | + ${{ runner.os }}-gradle- + + - name: Upload Build Artifacts + uses: actions/upload-artifact@v3 + with: + name: build-artifacts + path: ./build/ + test: needs: build runs-on: ubuntu-latest @@ -71,7 +87,8 @@ jobs: - name: Running Tests run: | - ./gradlew --no-daemon --info --refresh-dependencies spotlessCheck pmdMain pmdTest test + ./gradlew --no-daemon --info --refresh-dependencies spotlessCheck pmdMain pmdTest test -x build -x compileJava -x compileTestJava -x assemble + - name: Generate JavaDoc run: | From 7275f388dffbe1991025553e0104226e9faeedda Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Tue, 8 Oct 2024 19:42:34 +0200 Subject: [PATCH 093/117] Changed approach --- .github/workflows/ci.yml | 63 +++++++++------------------------------- 1 file changed, 14 insertions(+), 49 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e1870f98a4..d5f1b07453 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -22,11 +22,9 @@ jobs: build: runs-on: ubuntu-latest - container: - image: gradle:8.10-jdk17 steps: - - name: Checkout Code + - name: Checkout Source uses: actions/checkout@v4 with: ref: ${{ github.event.pull_request.head.ref || github.ref }} @@ -34,62 +32,29 @@ jobs: - name: Check Branch & Files run: | - git config --global --add safe.directory /__w/simona/simona git rev-parse --abbrev-ref HEAD pwd ls -la - - name: Checking Gradle & Java - run: | - java -version && gradle --version - - - name: Running Tests - run: | - ./gradlew --no-daemon --info --refresh-dependencies spotlessCheck pmdMain pmdTest test -x build -x compileJava -x compileTestJava -x assemble - - - - name: Generate JavaDoc - run: | - ./gradlew javadoc - - - name: Cache Gradle - uses: actions/cache@v3 - with: - path: | - ./gradle/ - key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} - restore-keys: | - ${{ runner.os }}-gradle- - - - name: Upload Build Artifacts - uses: actions/upload-artifact@v3 + - name: Setup Java + uses: actions/setup-java@v4 with: - name: build-artifacts - path: ./build/ - - test: - needs: build - runs-on: ubuntu-latest - container: - image: gradle:8.10-jdk17 - services: - docker: - image: docker:19.03.12 - options: --privileged + distribution: 'temurin' + java-version: 17 - steps: - - name: Checkout Code - uses: actions/checkout@v4 + - name: Setup Gradle 8.10 + uses: gradle/actions/setup-gradle@v4 with: - ref: ${{ github.event.pull_request.head.ref || github.ref }} - repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} + gradle-version: "8.10" + - name: Build Project + run: | + ./gradlew clean assemble - - name: Running Tests + - name: Run Tests run: | - ./gradlew --no-daemon --info --refresh-dependencies spotlessCheck pmdMain pmdTest test -x build -x compileJava -x compileTestJava -x assemble - + ./gradlew --refresh-dependencies spotlessCheck pmdMain pmdTest - - name: Generate JavaDoc + - name: Build Java-Docs run: | ./gradlew javadoc From 3eb67df2ba64de701454947addeeb9cbf04d416a Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Tue, 8 Oct 2024 20:17:07 +0200 Subject: [PATCH 094/117] Added Sonar --- .github/workflows/ci.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d5f1b07453..a0318519fa 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -58,3 +58,8 @@ jobs: - name: Build Java-Docs run: | ./gradlew javadoc + + - name: Run SonarQube with Gradle + run: ./gradlew sonarqube -Dsonar.projectKey=edu.ie3:simona \ + -Dsonar.host.url=${{ secrets.SONAR_HOST_URL }} \ + -Dsonar.login=${{ secrets.SONAR_TOKEN }} \ No newline at end of file From cc45c56b9c857f87eb54ee17e74fae0d00d5e8ba Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Wed, 9 Oct 2024 13:15:50 +0200 Subject: [PATCH 095/117] Added Sonar --- .github/workflows/ci.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a0318519fa..2959b0c65b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -53,13 +53,15 @@ jobs: - name: Run Tests run: | - ./gradlew --refresh-dependencies spotlessCheck pmdMain pmdTest + ./gradlew --refresh-dependencies spotlessCheck pmdMain pmdTest test - name: Build Java-Docs run: | ./gradlew javadoc + + #ADD reportScoverageTask - name: Run SonarQube with Gradle - run: ./gradlew sonarqube -Dsonar.projectKey=edu.ie3:simona \ + run: ./gradlew reportScoverage sonarqube -Dsonar.projectKey=edu.ie3:simona \ -Dsonar.host.url=${{ secrets.SONAR_HOST_URL }} \ -Dsonar.login=${{ secrets.SONAR_TOKEN }} \ No newline at end of file From 2ad00b1372c32391be42bd93b13b62ea2ffee623 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Wed, 9 Oct 2024 13:26:05 +0200 Subject: [PATCH 096/117] Added sonar credentials --- .github/workflows/ci.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2959b0c65b..3fba70782e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -59,9 +59,7 @@ jobs: run: | ./gradlew javadoc - - #ADD reportScoverageTask - name: Run SonarQube with Gradle - run: ./gradlew reportScoverage sonarqube -Dsonar.projectKey=edu.ie3:simona \ - -Dsonar.host.url=${{ secrets.SONAR_HOST_URL }} \ + run: ./gradlew reportScoverage sonarqube -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} \ + -Dsonar.host.url=${{ vars.SONAR_HOST_URL }} \ -Dsonar.login=${{ secrets.SONAR_TOKEN }} \ No newline at end of file From aaacfdb67ecc66e6fd25e7754495c135333fd5eb Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Wed, 16 Oct 2024 13:37:21 +0200 Subject: [PATCH 097/117] Moved reportScoverage --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3fba70782e..6875e6fbbf 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -53,13 +53,13 @@ jobs: - name: Run Tests run: | - ./gradlew --refresh-dependencies spotlessCheck pmdMain pmdTest test + ./gradlew --refresh-dependencies spotlessCheck pmdMain pmdTest test reportScoverage - name: Build Java-Docs run: | ./gradlew javadoc - name: Run SonarQube with Gradle - run: ./gradlew reportScoverage sonarqube -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} \ + run: ./gradlew sonarqube -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} \ -Dsonar.host.url=${{ vars.SONAR_HOST_URL }} \ -Dsonar.login=${{ secrets.SONAR_TOKEN }} \ No newline at end of file From 57534b87164816b2eeebd141de158e207501492b Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Wed, 16 Oct 2024 13:47:59 +0200 Subject: [PATCH 098/117] Moved reportScoverage --- .github/workflows/ci.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6875e6fbbf..bf054d403b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -53,7 +53,7 @@ jobs: - name: Run Tests run: | - ./gradlew --refresh-dependencies spotlessCheck pmdMain pmdTest test reportScoverage + ./gradlew --refresh-dependencies spotlessCheck pmdMain pmdTest test - name: Build Java-Docs run: | @@ -62,4 +62,5 @@ jobs: - name: Run SonarQube with Gradle run: ./gradlew sonarqube -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} \ -Dsonar.host.url=${{ vars.SONAR_HOST_URL }} \ - -Dsonar.login=${{ secrets.SONAR_TOKEN }} \ No newline at end of file + -Dsonar.login=${{ secrets.SONAR_TOKEN }} \ + reportScoverage sonarqube \ No newline at end of file From 9e2f3e85eb43878de9f2c9e02d95b36dd75c6667 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Wed, 16 Oct 2024 13:53:36 +0200 Subject: [PATCH 099/117] Moved reportScoverage --- .github/workflows/ci.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bf054d403b..4dc56c95c1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -60,7 +60,8 @@ jobs: ./gradlew javadoc - name: Run SonarQube with Gradle - run: ./gradlew sonarqube -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} \ + run: ./gradlew sonarqube \ + -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} \ -Dsonar.host.url=${{ vars.SONAR_HOST_URL }} \ -Dsonar.login=${{ secrets.SONAR_TOKEN }} \ - reportScoverage sonarqube \ No newline at end of file + -Dsonar.branch.name=${{ github.head_ref || github.ref_name }} \ No newline at end of file From 7d76f1706649acf35717014c1d31ed708455e0fd Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Wed, 16 Oct 2024 14:47:12 +0200 Subject: [PATCH 100/117] Switched to action --- .github/workflows/ci.yml | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4dc56c95c1..9c75713f5f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -59,9 +59,8 @@ jobs: run: | ./gradlew javadoc - - name: Run SonarQube with Gradle - run: ./gradlew sonarqube \ - -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} \ - -Dsonar.host.url=${{ vars.SONAR_HOST_URL }} \ - -Dsonar.login=${{ secrets.SONAR_TOKEN }} \ - -Dsonar.branch.name=${{ github.head_ref || github.ref_name }} \ No newline at end of file + - name: SonarQube Scan + uses: sonarsource/sonarqube-scan-action@ + env: + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }} \ No newline at end of file From 91a93662b30b3972ec5ceae457cc843aa70c8916 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Wed, 16 Oct 2024 14:48:00 +0200 Subject: [PATCH 101/117] Switched to action --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9c75713f5f..08dfe2ee9c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -60,7 +60,7 @@ jobs: ./gradlew javadoc - name: SonarQube Scan - uses: sonarsource/sonarqube-scan-action@ + uses: sonarsource/sonarqube-scan-action@v3 env: SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }} \ No newline at end of file From cfcabbf242892ebf6640452b4be886ebbe1010e7 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Wed, 16 Oct 2024 14:57:26 +0200 Subject: [PATCH 102/117] Back to gradle --- .github/workflows/ci.yml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 08dfe2ee9c..3a188e437a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -59,8 +59,5 @@ jobs: run: | ./gradlew javadoc - - name: SonarQube Scan - uses: sonarsource/sonarqube-scan-action@v3 - env: - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }} \ No newline at end of file + - name: Run SonarQube with Gradle + run: ./gradlew reportScoverage sonarqube -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} -Dsonar.host.url=${{ vars.SONAR_HOST_URL }} -Dsonar.login=${{ secrets.SONAR_TOKEN }} -Dsonar.branch.name=${{ github.head_ref || github.ref_name }} \ No newline at end of file From 1ff1b5a93e30a24d5d8042e238e56b5e230e7c66 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 11:51:38 +0200 Subject: [PATCH 103/117] Removed dependencies from sonarqube.gradle --- gradle/scripts/sonarqube.gradle | 3 --- 1 file changed, 3 deletions(-) diff --git a/gradle/scripts/sonarqube.gradle b/gradle/scripts/sonarqube.gradle index 80a9db4fd1..29a4bcc28a 100644 --- a/gradle/scripts/sonarqube.gradle +++ b/gradle/scripts/sonarqube.gradle @@ -34,8 +34,5 @@ sonarqube { } // sonarqube task dependencies -project.tasks["sonarqube"].dependsOn "pmdMain" -project.tasks["sonarqube"].dependsOn "pmdTest" -project.tasks["sonarqube"].dependsOn "test" project.tasks["sonarqube"].dependsOn "reportScoverage" project.tasks["sonarqube"].dependsOn "checkScoverage" From 58ada892407b2e9db574296ad75db83ae878a392 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 12:41:14 +0200 Subject: [PATCH 104/117] Added deployment step and sonar quality gate --- .github/workflows/ci.yml | 37 +++++++++++++++++++++++++++++++------ 1 file changed, 31 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3a188e437a..95b402d886 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -30,11 +30,12 @@ jobs: ref: ${{ github.event.pull_request.head.ref || github.ref }} repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }} - - name: Check Branch & Files + - name: Determine Project Version + id: version run: | - git rev-parse --abbrev-ref HEAD - pwd - ls -la + branch_name=$(echo ${{ github.ref_name }}) + project_version=$(./gradlew -q $([ "$branch_name" = "dev" ] && echo "devVersion" || echo "currentVersion")) + echo "project_version=${project_version}" >> $GITHUB_ENV - name: Setup Java uses: actions/setup-java@v4 @@ -59,5 +60,29 @@ jobs: run: | ./gradlew javadoc - - name: Run SonarQube with Gradle - run: ./gradlew reportScoverage sonarqube -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} -Dsonar.host.url=${{ vars.SONAR_HOST_URL }} -Dsonar.login=${{ secrets.SONAR_TOKEN }} -Dsonar.branch.name=${{ github.head_ref || github.ref_name }} \ No newline at end of file + - name: SonarQube Scan + run: | + ./gradlew reportScoverage sonarqube \ + -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} \ + -Dsonar.host.url=${{ vars.SONAR_HOST_URL }} \ + -Dsonar.login=${{ secrets.SONAR_TOKEN }} \ + -Dsonar.branch.name=${{ github.head_ref || github.ref_name }} + + - name: SonarQube Quality Gate + id: sonarqube-quality-gate-check + uses: sonarsource/sonarqube-quality-gate-action@master + # Force to fail step after specific time. + timeout-hours: 1 + env: + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }} + + - name: Deploy + if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/dev' + run: | + ./gradlew --refresh-dependencies test publish\ + -Puser=${{ secrets.MAVENCENTRAL_USER }} \ + -Ppassword=${{ secrets.MAVENCENTRAL_PASS }} \ + -Psigning.keyId=${{ secrets.MAVENCENTRAL_SIGNINGKEYID }} \ + -Psigning.password=${{ secrets.MAVENCENTRAL_SIGNINGPASS }} \ + -Psigning.secretKeyRingFile=${{ secrets.MAVENCENTRAL_SIGNINGKEY }} \ No newline at end of file From 50386fcda0ca6cda1908e7e29a34574045219333 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 12:42:01 +0200 Subject: [PATCH 105/117] fixed time format --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 95b402d886..65ab3d84e0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -72,7 +72,7 @@ jobs: id: sonarqube-quality-gate-check uses: sonarsource/sonarqube-quality-gate-action@master # Force to fail step after specific time. - timeout-hours: 1 + timeout-minutes: 60 env: SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }} From 33007be449d99f75d8420f30b64079f8a16d06a6 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 13:04:19 +0200 Subject: [PATCH 106/117] debug --- .github/workflows/ci.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 65ab3d84e0..6546cba77a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -68,6 +68,14 @@ jobs: -Dsonar.login=${{ secrets.SONAR_TOKEN }} \ -Dsonar.branch.name=${{ github.head_ref || github.ref_name }} + - name: Check if SonarQube Report Exists + id: verify-report + run: | + if [ ! -f ".scannerwork/report-task.txt" ]; then + echo "SonarQube report not found. Exiting." + exit 1 + fi + - name: SonarQube Quality Gate id: sonarqube-quality-gate-check uses: sonarsource/sonarqube-quality-gate-action@master From 5042d360e657848d51f2e91558c4bbfe9e09cbd5 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 13:35:50 +0200 Subject: [PATCH 107/117] Added dependencie to sonarqube.gradle and changed workflow --- .github/workflows/ci.yml | 2 +- gradle/scripts/sonarqube.gradle | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6546cba77a..a36d1ed2dc 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -54,7 +54,7 @@ jobs: - name: Run Tests run: | - ./gradlew --refresh-dependencies spotlessCheck pmdMain pmdTest test + ./gradlew --refresh-dependencies spotlessCheck pmdMain pmdTest - name: Build Java-Docs run: | diff --git a/gradle/scripts/sonarqube.gradle b/gradle/scripts/sonarqube.gradle index 29a4bcc28a..501bbbdc72 100644 --- a/gradle/scripts/sonarqube.gradle +++ b/gradle/scripts/sonarqube.gradle @@ -34,5 +34,6 @@ sonarqube { } // sonarqube task dependencies +project.tasks["sonarqube"].dependsOn "test" project.tasks["sonarqube"].dependsOn "reportScoverage" project.tasks["sonarqube"].dependsOn "checkScoverage" From 5c8ea2ba5c8f10d9dbb27f5e0bb1013dc68b6370 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 14:13:26 +0200 Subject: [PATCH 108/117] sonar --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a36d1ed2dc..1292b97813 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -62,7 +62,7 @@ jobs: - name: SonarQube Scan run: | - ./gradlew reportScoverage sonarqube \ + ./gradlew reportScoverage sonar \ -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} \ -Dsonar.host.url=${{ vars.SONAR_HOST_URL }} \ -Dsonar.login=${{ secrets.SONAR_TOKEN }} \ From e6b7e23a50e523a24c48e1993c00f67d0c966aa4 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 14:50:19 +0200 Subject: [PATCH 109/117] Switched to action --- .github/workflows/ci.yml | 24 +++++++++--------------- 1 file changed, 9 insertions(+), 15 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1292b97813..b2fe00ff39 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -60,21 +60,15 @@ jobs: run: | ./gradlew javadoc - - name: SonarQube Scan - run: | - ./gradlew reportScoverage sonar \ - -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} \ - -Dsonar.host.url=${{ vars.SONAR_HOST_URL }} \ - -Dsonar.login=${{ secrets.SONAR_TOKEN }} \ - -Dsonar.branch.name=${{ github.head_ref || github.ref_name }} - - - name: Check if SonarQube Report Exists - id: verify-report - run: | - if [ ! -f ".scannerwork/report-task.txt" ]; then - echo "SonarQube report not found. Exiting." - exit 1 - fi + - name: SonarQube Analysis + uses: sonarsource/sonarqube-scan-action@master + with: + projectBaseDir: '.' + args: > + -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} + env: + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }} - name: SonarQube Quality Gate id: sonarqube-quality-gate-check From 0a0174b35f6089a1245bd43ef9354e3666af443e Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 15:04:09 +0200 Subject: [PATCH 110/117] Added path to binaries --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b2fe00ff39..6fff761021 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -66,6 +66,7 @@ jobs: projectBaseDir: '.' args: > -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} + -Dsonar.java.binaries=build/classes/java/main,build/classes/scala/main env: SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }} From 00fd90a4eff6d66b4f7c67fac88b52e1a442efa5 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 15:10:25 +0200 Subject: [PATCH 111/117] Added path to binaries --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6fff761021..48e82a37cc 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -66,7 +66,7 @@ jobs: projectBaseDir: '.' args: > -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} - -Dsonar.java.binaries=build/classes/java/main,build/classes/scala/main + -Dsonar.java.binaries=build/classes/java/main env: SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }} From fa44b062f6055275bfb3b1f9c10c0a2fdae87758 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 15:27:57 +0200 Subject: [PATCH 112/117] Debug --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 48e82a37cc..4ccdf1a69d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -59,6 +59,7 @@ jobs: - name: Build Java-Docs run: | ./gradlew javadoc + ls -la - name: SonarQube Analysis uses: sonarsource/sonarqube-scan-action@master From d203385e3c601e9288c4b5e73bbd0b51bdf0b715 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 15:32:24 +0200 Subject: [PATCH 113/117] Debug --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4ccdf1a69d..79b9480484 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -67,7 +67,7 @@ jobs: projectBaseDir: '.' args: > -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} - -Dsonar.java.binaries=build/classes/java/main + -Dsonar.java.binaries=build/classes/scala/main env: SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }} From 1ff759cb1dabd95c0b9f8ded55981cb569b4653a Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 15:45:13 +0200 Subject: [PATCH 114/117] Debug --- .github/workflows/ci.yml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 79b9480484..eaf56da627 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -68,6 +68,15 @@ jobs: args: > -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} -Dsonar.java.binaries=build/classes/scala/main + -Dsonar.verbose=true + -Dsonar.sourceEncoding=UTF-8 + -Dsonar.sources=src/main/resources,src/main/scala + -Dsonar.tests=src/test/resources,src/test/scala,src/test/groovy + -Dsonar.junit.reportPaths=build/test-results/test + -Dsonar.scala.scapegoat.reportPaths=build/reports/scapegoat/src/scapegoat-scalastyle.xml,build/reports/scapegoat/testsrc/scapegoat-scalastyle.xml + -Dsonar.scala.coverage.reportPaths=build/reports/scoverageTest/scoverage.xml + -Dsonar.groovy.binaries=build/classes/groovy + -Dsonar.exclusions=src/main/scala/edu/ie3/simona/config/SimonaConfig.scala env: SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }} From 9d5d39580502e935a0068c72fc38ab7d3c1aea00 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 15:53:12 +0200 Subject: [PATCH 115/117] Finished Prototype --- .github/workflows/ci.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index eaf56da627..cc0d644944 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -54,12 +54,11 @@ jobs: - name: Run Tests run: | - ./gradlew --refresh-dependencies spotlessCheck pmdMain pmdTest + ./gradlew --refresh-dependencies spotlessCheck pmdMain pmdTest test - name: Build Java-Docs run: | ./gradlew javadoc - ls -la - name: SonarQube Analysis uses: sonarsource/sonarqube-scan-action@master From 15ef2df51068a33385c073597eb404ac16d955b4 Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 16:02:25 +0200 Subject: [PATCH 116/117] Finished Prototype --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index cc0d644944..a4101376dd 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -54,7 +54,7 @@ jobs: - name: Run Tests run: | - ./gradlew --refresh-dependencies spotlessCheck pmdMain pmdTest test + ./gradlew --refresh-dependencies spotlessCheck pmdMain pmdTest - name: Build Java-Docs run: | From a8fd9ee36d739a6261b822fe83ab4a827d8a87fa Mon Sep 17 00:00:00 2001 From: PhilippSchmelter Date: Thu, 17 Oct 2024 16:19:10 +0200 Subject: [PATCH 117/117] Changed Java-Docs to Scala-Docs --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a4101376dd..7c7576f9da 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -56,9 +56,9 @@ jobs: run: | ./gradlew --refresh-dependencies spotlessCheck pmdMain pmdTest - - name: Build Java-Docs + - name: Build Scala-Docs run: | - ./gradlew javadoc + ./gradlew scaladoc - name: SonarQube Analysis uses: sonarsource/sonarqube-scan-action@master