-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
2 changed files
with
66 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
name: backport | ||
|
||
# backport by issue a label (backport <target branch>) on merged PR | ||
|
||
on: | ||
pull_request_target: | ||
types: [closed, labeled] | ||
jobs: | ||
backport: | ||
permissions: | ||
contents: write # so it can comment | ||
pull-requests: write # so it can create pull requests | ||
name: Backport Pull Request | ||
if: github.event.pull_request.merged | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Create backport PRs | ||
uses: korthout/backport-action@v2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: Python package | ||
|
||
# necessary check for Python project, publish to PyPI performed locally | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
tags: | ||
- v* | ||
pull_request: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
py-package: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- run: | | ||
pip install --no-cache-dir poetry | ||
- name: verify | ||
if: startsWith(github.ref, 'refs/tags/v') | ||
run: | | ||
py_version=$(poetry version --short) | ||
VERSION=$(echo "${{ github.ref }}" | sed -e 's,.*/\(.*\),\1,') | ||
tag_version=${VERSION#v} | ||
if [[ $py_version != $tag_version ]] ; then | ||
echo "publish version does not match, $py_version vs $tag_version" | ||
exit 1 | ||
fi | ||
- name: build | ||
run: | | ||
poetry install | ||
poetry build | ||
- name: Release | ||
uses: softprops/action-gh-release@v1 | ||
if: startsWith(github.ref, 'refs/tags/v') | ||
with: | ||
files: | | ||
./openmldb_mixin/openmldb_dashboard.json | ||