Skip to content

Commit b6cbefb

Browse files
committed
add github release action
1 parent 9c81f21 commit b6cbefb

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

.github/workflows/release.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
name: Release Plugin
3+
on:
4+
push:
5+
branches:
6+
- master
7+
jobs:
8+
build:
9+
# TODO only when test successful
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Checkout
13+
uses: actions/checkout@v4
14+
- name: Package
15+
run: |
16+
version=$(sed -n ''s/\s*$plugin->version\s*=\s\([0-9]*\);.*/\1/p'' version.php)
17+
echo "version: ${version}"
18+
ls -la
19+
zip local_auth_${version}.zip . -r -x '*.git/*'
20+
- name: Release
21+
uses: softprops/action-gh-release@v2
22+
with:
23+
files: local_auth_${version}.zip

0 commit comments

Comments
 (0)