Skip to content

Commit b5f869a

Browse files
committed
ci: setup release action
1 parent 906d7a2 commit b5f869a

File tree

3 files changed

+46
-3
lines changed

3 files changed

+46
-3
lines changed

.github/workflows/ci.yml

+7-3
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,12 @@ jobs:
77
runs-on: ubuntu-latest
88
steps:
99
- uses: actions/checkout@v4
10+
with:
11+
token: ${{ secrets.GITHUB_TOKEN }}
1012
- name: Stylua
1113
uses: JohnnyMorganz/stylua-action@v4
1214
with:
13-
token: ${{ secrets.GH_VIMDOC_TOKEN }}
15+
token: ${{ secrets.GITHUB_TOKEN }}
1416
version: latest
1517
args: --check .
1618

@@ -21,7 +23,7 @@ jobs:
2123
steps:
2224
- uses: actions/checkout@v4
2325
with:
24-
token: ${{ secrets.GH_VIMDOC_TOKEN }}
26+
token: ${{ secrets.GITHUB_TOKEN }}
2527
- name: panvimdoc
2628
uses: kdheepak/panvimdoc@main
2729
with:
@@ -41,6 +43,8 @@ jobs:
4143
contents: write
4244
steps:
4345
- uses: actions/checkout@v4
46+
with:
47+
token: ${{ secrets.GITHUB_TOKEN }}
4448
- uses: rhysd/action-setup-vim@v1
4549
id: vim
4650
with:
@@ -50,7 +54,7 @@ jobs:
5054
- name: luajit
5155
uses: leafo/gh-actions-lua@v10
5256
with:
53-
luaVersion: "luajit-2.1.0-beta3"
57+
luaVersion: "luajit-openresty"
5458

5559
- name: luarocks
5660
uses: leafo/gh-actions-luarocks@v4

.github/workflows/release.yml

+38
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Release
2+
on:
3+
push:
4+
branches:
5+
- release
6+
pull_request:
7+
branches:
8+
- main
9+
- release
10+
11+
permissions:
12+
contents: write
13+
pull-requests: write
14+
15+
jobs:
16+
release:
17+
name: release
18+
runs-on: ubuntu-latest
19+
steps:
20+
- uses: google-github-actions/release-please-action@v4
21+
id: release
22+
with:
23+
release-type: simple
24+
package-name: quick-code-runner.nvim
25+
token: ${{ secrets.GITHUB_TOKEN }}
26+
- uses: actions/checkout@v4
27+
with:
28+
token: ${{ secrets.GITHUB_TOKEN }}
29+
- name: tag stable versions
30+
if: ${{ steps.release.outputs.release_created }}
31+
run: |
32+
git config user.name github-actions[bot]
33+
git config user.email github-actions[bot]@users.noreply.github.com
34+
git remote add gh-token "https://${{ secrets.GITHUB_TOKEN }}@github.com/google-github-actions/release-please-action.git"
35+
git tag -d stable || true
36+
git push origin :stable || true
37+
git tag -a stable -m "Last Stable Release"
38+
git push origin stable

version.txt

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
0.1.0

0 commit comments

Comments
 (0)