Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
OR13 committed Aug 10, 2024
1 parent 702689f commit d47ed37
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ jobs:
uses: ./
with:
transmute: |
jose keygen --alg ES256 -v
jose keygen --alg ES256 --verbose
- name: Log Private Key
run: echo "${{ steps.private_key.outputs.json }}"
6 changes: 4 additions & 2 deletions src/jose/handler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { env } from '../action'

const prettyKey = (k: jose.JWK) => {
const { kid, kty, crv, alg, x, y, d } = k
return JSON.stringify({ kid, kty, crv, alg, x, y, d }, null, 2)
return { kid, kty, crv, alg, x, y, d }
}

export const handler = async function ({ positionals, values }: PositionalArguments) {
Expand All @@ -27,7 +27,9 @@ export const handler = async function ({ positionals, values }: PositionalArgume
}
const output = prettyKey(privateKey)
if (env.github()) {
setSecret(output)
if (output.d) {
setSecret(output.d)
}
setOutput('json', output)
} else {
console.log(output)
Expand Down

0 comments on commit d47ed37

Please sign in to comment.