Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.
Mirrored from https://github.com/Camo67/composio.git
Synced Nov 23, 01:45 UTC
Add github workflow
haxzie committed
May 29, 2025 at 15:44 UTC
de40f2fe9613efd25855660fa00e1b21b5be72e0
1 file changed
+35
-18
.github/workflows/release.yml
+35
-18
@@ -1,36 +1,53 @@
1
-name: Release & Publish
1
+name: TS SDK Release
2
3
on:
4
+ workflow_dispatch:
5
push:
5
- branches:
6
- - main
6
+ branches: [master]
7
+
8
+env:
9
+ GITHUB_ACCESS_TOKEN: ${{ secrets.CI_BOT_TOKEN }}
10
11
jobs:
12
release:
10
- name: Version Bump, Release, and Publish
13
+ name: Release
14
runs-on: ubuntu-latest
12
-
15
steps:
14
- - name: Checkout code
15
- uses: actions/checkout@v4
16
+ - name: Checkout Code
17
+ uses: actions/checkout@v3
18
+
19
+ - name: Setup PNPM
20
+ uses: pnpm/action-setup@v2
21
with:
17
- fetch-depth: 0
22
+ version: 10.8.0 # Match the version in package.json
23
19
- - name: Setup Node.js
20
- uses: actions/setup-node@v4
24
+ - name: Set up Node.js
25
+ uses: actions/setup-node@v3
26
with:
22
- node-version: 18
23
- registry-url: 'https://registry.npmjs.org'
27
+ node-version: '20'
28
+ cache: 'pnpm'
29
25
- - name: Install dependencies
26
- run: pnpm install
27
- shell: bash
30
+ - name: Install Dependencies
31
+ run: pnpm install --frozen-lockfile
32
29
- - name: Create version PR or publish
33
+ - name: Run Linting
34
+ run: pnpm lint
35
+
36
+ - name: Run Build
37
+ run: pnpm run build
38
+ - name: Create Release Pull Request & Publish packages
39
+ id: changesets
40
uses: changesets/action@v1
41
+ if: github.event_name != 'workflow_dispatch' # only run on master merges
42
+ env:
43
+ GITHUB_TOKEN: ${{ secrets.CI_BOT_TOKEN }}
44
with:
32
- version: pnpm changeset:version
45
publish: pnpm changeset:release
46
+ commit: 'build: update version'
47
+ title: 'build: update version'
48
+ - name: Publish to public npm registry
49
+ if: steps.changesets.outputs.published == 'true' || github.event_name == 'workflow_dispatch' # run when the package is published via changeset or if a release is triggered manually.
50
env:
35
- GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
51
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
52
+ PUBLISHED_PACKAGES: ${{ steps.changesets.outputs.publishedPackages }}
53
+ run: yarn publish-npm