Skip to content

Commit

Permalink
feat: release pipeline
Browse files Browse the repository at this point in the history
Signed-off-by: Berend Sliedrecht <[email protected]>
  • Loading branch information
berendsliedrecht committed Jun 14, 2024
1 parent c5dfd70 commit 4df4f64
Show file tree
Hide file tree
Showing 4 changed files with 1,772 additions and 275 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,3 +49,42 @@ jobs:

- name: Test
run: pnpm test

continious-deployment:
if: github.event_name == 'workflow_dispatch'

name: 'Continous Deployment'
runs-on: ubuntu-latest
needs: ['continous-integration']

steps:
- uses: actions/checkout@v4

- uses: pnpm/action-setup@v4
with:
version: 9

- name: Install dependencies
run: pnpm install

- name: Build
run: pnpm build

- name: Set git configuration
run: |
git config user.name "Animo Solutions"
git config user.email "[email protected]"
- name: Publish
id: publish
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
npm config set //registry.npmjs.org/:_authToken $NPM_TOKEN
if [ ${{ inputs.release-type }} == 'alpha' ]; then
pnpm release --preRelease=alpha
else
pnpm release -i=${{ inputs.release-type }}
fi
8 changes: 8 additions & 0 deletions .release-it.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"git": {
"commitMessage": "chore: release v${version}"
},
"github": {
"release": true
}
}
8 changes: 5 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"name": "askar-webcrypto",
"name": "@animo-id/askar-webcrypto",
"version": "0.0.0",
"main": "build/index.js",
"author": "Animo Solutions <[email protected]> (https://animo.id)",
"author": "Animo Solutions <[email protected]> (https://www.animo.id)",
"repository": {
"url": "https://github.com/animo/askar-webcrypto",
"type": "git"
Expand All @@ -19,7 +19,8 @@
"lint": "biome lint .",
"lint:fix": "pnpm lint --write --unsafe",
"check-types": "pnpm build --noEmit",
"test": "node --import tsx --test ./tests/*.test.ts"
"test": "node --import tsx --test ./tests/*.test.ts",
"release": "release-it"
},
"dependencies": {
"@credo-ts/core": "^0.5.3",
Expand All @@ -36,6 +37,7 @@
"@hyperledger/aries-askar-nodejs": "^0.2.1",
"@peculiar/x509": "^1.11.0",
"@types/node": "^20.14.2",
"release-it": "^17.3.0",
"tsx": "^4.15.2",
"typescript": "~5.4.5"
}
Expand Down
Loading

0 comments on commit 4df4f64

Please sign in to comment.