Skip to content

Commit bf3eeb9

Browse files
committed
Fix Workflow
1 parent a408aae commit bf3eeb9

File tree

2 files changed

+15
-7
lines changed

2 files changed

+15
-7
lines changed

.github/workflows/codeql.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,18 +27,18 @@ jobs:
2727
uses: actions/checkout@v3
2828

2929
- name: Initialize CodeQL
30-
uses: github/codeql-action/init@v2
30+
uses: github/codeql-action/init@v3
3131
with:
3232
languages: ${{ matrix.language }}
3333

3434
- name: Set up JDK
3535
uses: actions/setup-java@v3
3636
with:
37-
java-version: '23' # Or your actual Java version
37+
java-version: '23'
3838
distribution: 'temurin'
3939

40-
- name: Build project with Maven
41-
run: mvn clean install
40+
- name: Build project with Maven (GPG disabled)
41+
run: mvn clean install -Dgpg.skip=true
4242

4343
- name: Perform CodeQL Analysis
44-
uses: github/codeql-action/analyze@v2
44+
uses: github/codeql-action/analyze@v3

.github/workflows/maven.yml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,5 +20,13 @@ jobs:
2020
java-version: '23'
2121
distribution: 'temurin'
2222

23-
- name: Build with Maven
24-
run: mvn clean install
23+
- name: Import GPG key
24+
run: |
25+
echo "$GPG_PRIVATE_KEY" | gpg --batch --import
26+
echo "allow-loopback-pinentry" >> ~/.gnupg/gpg-agent.conf
27+
echo "pinentry-mode loopback" >> ~/.gnupg/gpg.conf
28+
env:
29+
GPG_PRIVATE_KEY: ${{ secrets.GPG_PRIVATE_KEY }}
30+
31+
- name: Build with Maven (GPG Enabled)
32+
run: mvn -B clean install -Dgpg.passphrase="${{ secrets.GPG_PASSPHRASE }}" -Dgpg.pinentry.mode=loopback

0 commit comments

Comments
 (0)