@@ -59,13 +59,28 @@ jobs:
5959 server-username : MAVEN_USERNAME
6060 server-password : MAVEN_TOKEN
6161 gpg-passphrase : GPG_PASSPHRASE # env variable for GPG private key passphrase
62+ - name : Verify secrets access
63+ run : |
64+ echo "List of available secrets:"
65+ echo "GPG_PRIVATE_KEY exists: ${{ secrets.GPG_PRIVATE_KEY != '' }}"
66+ echo "GPG_PASSPHRASE exists: ${{ secrets.GPG_PASSPHRASE != '' }}"
67+ - name : test gpg
68+ env :
69+ GPG_PRIVATE_KEY : ${{ secrets.GPG_PRIVATE_KEY }}
70+ run : |
71+ echo "GPG key length: ${#GPG_PRIVATE_KEY}"
72+ echo "First 10 lines:"
73+ echo "$GPG_PRIVATE_KEY" | head -n 10
74+ echo "Last 10 lines:"
75+ echo "$GPG_PRIVATE_KEY" | tail -n 10
6276
6377 - name : Import GPG key
6478 id : import_gpg
65- if : github.event_name == 'push'
79+ # if: github.event_name == 'push'
6680 uses : crazy-max/ghaction-import-gpg@v4
6781 with :
6882 gpg_private_key : ${{ secrets.GPG_PRIVATE_KEY }}
83+ passphrase : ${{ secrets.GPG_PASSPHRASE }}
6984
7085 - name : Cache local Maven repository
7186 uses : actions/cache@v3
86101 make build
87102
88103 - name : upload linux library
89- if : github.event_name == 'push'
104+ # if: github.event_name == 'push'
90105 uses : actions/upload-artifact@v4
91106 with :
92107 name : shared-library-${{ github.sha }}
@@ -121,12 +136,11 @@ jobs:
121136 java/*/target/**/TEST-*.xml
122137
123138 - name : deploy
124- if : github.event_name == 'push'
139+ # if: github.event_name == 'push'
125140 working-directory : java
126141 run : |
127142 ./mvnw --batch-mode deploy -DskipTests=true -Dscalatest.skip=true
128143 env :
129- MAVEN_OPTS : -Duser.home=/github/home
130144 MAVEN_USERNAME : ${{ secrets.OSSRH_USERNAME }}
131145 MAVEN_TOKEN : ${{ secrets.OSSRH_TOKEN }}
132146 GPG_PASSPHRASE : ${{ secrets.GPG_PASSPHRASE }}
0 commit comments