Skip to content

Commit de39b90

Browse files
ci (dataprotectord-deserializer) : fix workflow
1 parent 5a9a604 commit de39b90

File tree

2 files changed

+39
-25
lines changed

2 files changed

+39
-25
lines changed
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Publish Package NPM
2+
3+
on:
4+
workflow_dispatch:
5+
inputs:
6+
tag:
7+
description: 'NPM tag to publish (latest or nightly)'
8+
required: true
9+
type: choice
10+
options:
11+
- latest
12+
- nightly
13+
default: nightly
14+
15+
jobs:
16+
set-env:
17+
runs-on: ubuntu-latest
18+
outputs:
19+
resolved-environment: ${{ steps.setenv.outputs.env }}
20+
steps:
21+
- id: setenv
22+
run: |
23+
if [ "${{ github.event.inputs.tag }}" = "latest" ]; then
24+
echo "env=production" >> $GITHUB_OUTPUT
25+
else
26+
echo "env=staging" >> $GITHUB_OUTPUT
27+
fi
28+
29+
publish-npm:
30+
needs: set-env
31+
uses: iExecBlockchainComputing/github-actions-workflows/.github/workflows/[email protected]
32+
with:
33+
scope: '@iexec/deserializer'
34+
registry: 'https://registry.npmjs.org'
35+
node-version: '18'
36+
environment: ${{ needs.set-env.outputs.resolved-environment }}
37+
working-directory: "packages/dataprotector-deserializer"
38+
secrets:
39+
npm-token: ${{ secrets.NPM_TOKEN }}

github/workflows/publish-npm-deserializer.yml

Lines changed: 0 additions & 25 deletions
This file was deleted.

0 commit comments

Comments
 (0)