@@ -39,13 +39,33 @@ jobs:
39
39
- name : Copy README
40
40
run : cp README.md libs/react-plock/dist/
41
41
42
- - name : Manual Release
42
+ # - name: Manual Release
43
+ # env:
44
+ # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
45
+ # NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
46
+ # VERSION: ${{ inputs.version }}
47
+ # run: |
48
+ # git config --global user.email "github-actions[bot]@users.noreply.github.com"
49
+ # git config --global user.name "github-actions[bot]"
50
+ # npm version $VERSION
51
+ # pnpm --filter react-plock publish
52
+
53
+ - name : Generate Changelog
54
+ id : changelog
55
+ run : |
56
+ PREVIOUS_TAG=$(git describe --tags --abbrev=0 HEAD^)
57
+ CHANGELOG=$(git log --pretty=format:"- %s" ${PREVIOUS_TAG}..HEAD)
58
+ echo "CHANGELOG<<EOF" >> $GITHUB_ENV
59
+ echo "$CHANGELOG" >> $GITHUB_ENV
60
+ echo "EOF" >> $GITHUB_ENV
61
+
62
+ - name : Create GitHub Release
63
+ uses : actions/create-release@v1
43
64
env :
44
65
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
45
- NPM_TOKEN : ${{ secrets.NPM_TOKEN }}
46
- VERSION : ${{ inputs.version }}
47
- run : |
48
- git config --global user.email "github-actions[bot]@users.noreply.github.com"
49
- git config --global user.name "github-actions[bot]"
50
- npm version $VERSION
51
- pnpm --filter react-plock publish
66
+ with :
67
+ tag_name : v${{ inputs.version }}
68
+ release_name : v${{ inputs.version }}
69
+ body : ${{ env.CHANGELOG }}
70
+ draft : false
71
+ prerelease : false
0 commit comments