-
Notifications
You must be signed in to change notification settings - Fork 0
48 lines (39 loc) · 1.27 KB
/
publish.yml
File metadata and controls
48 lines (39 loc) · 1.27 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: Publish
on:
push:
branches:
- 'release/package'
jobs:
test:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- name: Restore dependencies
run: dotnet restore tests/Needle.Engine.TypescriptCodegen.Tests.csproj
- name: Build
run: dotnet build tests/Needle.Engine.TypescriptCodegen.Tests.csproj --no-restore
- name: Run tests
run: dotnet test tests/Needle.Engine.TypescriptCodegen.Tests.csproj --no-build --verbosity normal
publish:
needs: test
runs-on: ubuntu-latest
timeout-minutes: 5
defaults:
run:
working-directory: package
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
- name: Publish to npm
id: publish
run: npx --yes needle-publish-helper@stable publish "." --webhook "${{ secrets.WEBHOOK_URL }}" --registry "${{ secrets.PACKAGE_REGISTRY_URL }}" --access-token "${{ secrets.NPM_TOKEN }}" --create-tag release/ --llm-api-key "${{ secrets.LLM_API_KEY }}"