mirror of
https://github.com/crazy-max/ghaction-import-gpg.git
synced 2024-11-25 14:31:03 -05:00
Dedicated CI job for base64
This commit is contained in:
parent
15c79ac393
commit
db752f495e
1 changed files with 31 additions and 9 deletions
40
.github/workflows/ci.yml
vendored
40
.github/workflows/ci.yml
vendored
|
@ -11,7 +11,7 @@ on:
|
||||||
- '**.md'
|
- '**.md'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
ci:
|
armored:
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
|
@ -32,10 +32,9 @@ jobs:
|
||||||
script: |
|
script: |
|
||||||
const fs = require('fs');
|
const fs = require('fs');
|
||||||
core.setOutput('pgp', fs.readFileSync('.github/test-key.pgp', {encoding: 'utf8'}));
|
core.setOutput('pgp', fs.readFileSync('.github/test-key.pgp', {encoding: 'utf8'}));
|
||||||
core.setOutput('pgp-base64', fs.readFileSync('.github/test-key-base64.pgp', {encoding: 'utf8'}));
|
|
||||||
core.setOutput('passphrase', fs.readFileSync('.github/test-key.pass', {encoding: 'utf8'}));
|
core.setOutput('passphrase', fs.readFileSync('.github/test-key.pass', {encoding: 'utf8'}));
|
||||||
-
|
-
|
||||||
name: Import GPG private key
|
name: Import GPG
|
||||||
id: import_gpg
|
id: import_gpg
|
||||||
uses: ./
|
uses: ./
|
||||||
with:
|
with:
|
||||||
|
@ -53,9 +52,32 @@ jobs:
|
||||||
echo "keyid: ${{ steps.import_gpg.outputs.keyid }}"
|
echo "keyid: ${{ steps.import_gpg.outputs.keyid }}"
|
||||||
echo "name: ${{ steps.import_gpg.outputs.name }}"
|
echo "name: ${{ steps.import_gpg.outputs.name }}"
|
||||||
echo "email: ${{ steps.import_gpg.outputs.email }}"
|
echo "email: ${{ steps.import_gpg.outputs.email }}"
|
||||||
|
|
||||||
|
base64:
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
os:
|
||||||
|
- ubuntu-latest
|
||||||
|
- macOS-latest
|
||||||
|
- windows-latest
|
||||||
|
steps:
|
||||||
-
|
-
|
||||||
name: Import GPG private key in base64 format
|
name: Checkout
|
||||||
id: import_gpg_base64
|
uses: actions/checkout@v2
|
||||||
|
-
|
||||||
|
name: Get test key and passphrase
|
||||||
|
uses: actions/github-script@0.9.0
|
||||||
|
id: test
|
||||||
|
with:
|
||||||
|
script: |
|
||||||
|
const fs = require('fs');
|
||||||
|
core.setOutput('pgp-base64', fs.readFileSync('.github/test-key-base64.pgp', {encoding: 'utf8'}));
|
||||||
|
core.setOutput('passphrase', fs.readFileSync('.github/test-key.pass', {encoding: 'utf8'}));
|
||||||
|
-
|
||||||
|
name: Import GPG
|
||||||
|
id: import_gpg
|
||||||
uses: ./
|
uses: ./
|
||||||
with:
|
with:
|
||||||
git_user_signingkey: true
|
git_user_signingkey: true
|
||||||
|
@ -68,7 +90,7 @@ jobs:
|
||||||
-
|
-
|
||||||
name: GPG user IDs
|
name: GPG user IDs
|
||||||
run: |
|
run: |
|
||||||
echo "fingerprint: ${{ steps.import_gpg_base64.outputs.fingerprint }}"
|
echo "fingerprint: ${{ steps.import_gpg.outputs.fingerprint }}"
|
||||||
echo "keyid: ${{ steps.import_gpg_base64.outputs.keyid }}"
|
echo "keyid: ${{ steps.import_gpg.outputs.keyid }}"
|
||||||
echo "name: ${{ steps.import_gpg_base64.outputs.name }}"
|
echo "name: ${{ steps.import_gpg.outputs.name }}"
|
||||||
echo "email: ${{ steps.import_gpg_base64.outputs.email }}"
|
echo "email: ${{ steps.import_gpg.outputs.email }}"
|
||||||
|
|
Loading…
Reference in a new issue