5
5
tags :
6
6
- ' v*' # Trigger on version tags (v1.0.0, v1.2.3, etc.)
7
7
8
+ permissions :
9
+ contents : write # This is required for creating releases and uploading assets
10
+
8
11
jobs :
9
12
build :
10
13
runs-on : macos-latest
@@ -30,14 +33,18 @@ jobs:
30
33
id : get_version
31
34
run : echo "VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_OUTPUT
32
35
36
+ - name : Create package archive
37
+ run : |
38
+ mkdir -p dist-package
39
+ cp -r dist package.json README.md LICENSE dist-package/
40
+ cd dist-package
41
+ npm pack
42
+ mv *.tgz ../applescript-mcp-${{ steps.get_version.outputs.VERSION }}.tgz
43
+
33
44
- name : Create GitHub Release
34
- id : create_release
35
- uses : actions/create-release@v1
36
- env :
37
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
45
+ uses : softprops/action-gh-release@v1
38
46
with :
39
- tag_name : ${{ github.ref }}
40
- release_name : Release ${{ github.ref_name }}
47
+ name : Release ${{ github.ref_name }}
41
48
draft : false
42
49
prerelease : false
43
50
body : |
@@ -46,27 +53,11 @@ jobs:
46
53
## Changes
47
54
48
55
<!-- Add your release notes here -->
49
-
50
- - name : Create package archive
51
- run : |
52
- mkdir -p dist-package
53
- cp -r dist package.json README.md LICENSE dist-package/
54
- cd dist-package
55
- npm pack
56
- mv *.tgz ../applescript-mcp-${{ steps.get_version.outputs.VERSION }}.tgz
57
-
58
- - name : Upload Release Asset
59
- uses : actions/upload-release-asset@v1
60
- env :
61
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
62
- with :
63
- upload_url : ${{ steps.create_release.outputs.upload_url }}
64
- asset_path : ./applescript-mcp-${{ steps.get_version.outputs.VERSION }}.tgz
65
- asset_name : applescript-mcp-${{ steps.get_version.outputs.VERSION }}.tgz
66
- asset_content_type : application/gzip
56
+ files : |
57
+ ./applescript-mcp-${{ steps.get_version.outputs.VERSION }}.tgz
67
58
68
59
# Uncomment the following step if you want to publish to npm
69
60
# - name: Publish to npm
70
61
# run: npm publish
71
62
# env:
72
- # NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
63
+ # NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
0 commit comments