@@ -2,10 +2,8 @@ name: Publish
2
2
3
3
on :
4
4
push :
5
- branches :
6
- - main
7
- # tags:
8
- # - 'v[1-9].*'
5
+ tags :
6
+ - ' v[1-9].*'
9
7
10
8
jobs :
11
9
build :
21
19
with :
22
20
node-version : 22
23
21
registry-url : ' https://registry.npmjs.org'
22
+
24
23
- name : Restore C# dependencies
25
24
run : dotnet restore
26
25
- name : Restore eslint-config-rock-recommended dependencies
@@ -29,18 +28,25 @@ jobs:
29
28
- name : Restore obsidian-build-tools dependencies
30
29
run : npm ci
31
30
working-directory : ./src/obsidian-build-tools
31
+
32
32
- name : Build C#
33
33
run : dotnet build --no-restore
34
+ - name : Build obsidian-build-tools
35
+ run : npm run build
36
+ working-directory : ./src/obsidian-build-tools
37
+
34
38
- name : Test
35
39
run : dotnet test --no-build --verbosity normal
40
+
36
41
- name : Pack C#
37
42
run : dotnet pack --output .
38
- - name : Build obsidian-build-tools
39
- run : npm run build
40
- working-directory : ./src/obsidian-build-tools
41
43
- name : Pack obsidian-build-tools
42
44
run : npm pack --pack-destination ../..
43
45
working-directory : ./src/obsidian-build-tools
46
+ - name : Pack eslint-config-rock-recommended
47
+ run : npm pack --pack-destination ../..
48
+ working-directory : ./src/eslint-config-rock-recommended
49
+
44
50
- name : Archive NuGet packages
45
51
uses : actions/upload-artifact@v4
46
52
with :
@@ -55,15 +61,16 @@ jobs:
55
61
path : " *.tgz"
56
62
if-no-files-found : error
57
63
retention-days : 30
64
+
58
65
- name : Publish eslint-config-rock-recommended
59
- run : npm publish --dry-run -- access public
66
+ run : npm publish --access public
60
67
working-directory : ./src/eslint-config-rock-recommended
61
68
env :
62
69
NODE_AUTH_TOKEN : ${{ secrets.NPM_API_KEY }}
63
70
- name : Publish obsidian-build-tools
64
- run : npm publish --dry-run -- access public
71
+ run : npm publish --access public
65
72
working-directory : ./src/obsidian-build-tools
66
73
env :
67
74
NODE_AUTH_TOKEN : ${{ secrets.NPM_API_KEY }}
68
- # - name: Publish
69
- # run: dotnet nuget push *.nupkg --api-key ${{ secrets.NUGET_API_KEY }}
75
+ - name : Publish
76
+ run : dotnet nuget push *.nupkg --api-key ${{ secrets.NUGET_API_KEY }}
0 commit comments