Skip to content

Commit

Permalink
ci: adding cd pipeline from algokit utils ts
Browse files Browse the repository at this point in the history
  • Loading branch information
aorumbayev committed Jan 8, 2025
1 parent a2d7c55 commit 89623bb
Show file tree
Hide file tree
Showing 4 changed files with 7,756 additions and 2,030 deletions.
67 changes: 67 additions & 0 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
name: Publish

on:
push:
branches:
- main
- release
workflow_dispatch:

concurrency: release

permissions:
contents: write
issues: read

jobs:
ci:
name: Continuous Integration
uses: ./.github/workflows/ci.yml

build:
name: Build
uses: makerxstudio/shared-config/.github/workflows/node-build-zip.yml@main
needs:
- ci
- check_docs
with:
node-version: 20.x
build-path: dist
artifact-name: package

release:
name: Release
needs: build
runs-on: ubuntu-latest
steps:
- name: Clone repository
uses: actions/checkout@v3
with:
fetch-depth: 0

# semantic-release needs node 20
- name: Use Node.js 20.x
uses: actions/setup-node@v3
with:
node-version: 20.x

- name: Download built package
uses: actions/download-artifact@v4
with:
name: package
path: artifacts

- name: Unzip package
shell: bash
run: |
mkdir -p dist
unzip -q "artifacts/package.zip" -d dist
- name: Install dependencies to get semantic release components and plugins
run: npm ci --ignore-scripts

- name: 'Semantic release'
run: npx semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
branches:
- main
pull_request:
workflow_call:
jobs:
test:
runs-on: ${{ matrix.os }}
Expand Down
Loading

0 comments on commit 89623bb

Please sign in to comment.