feat: merge databend driver #22
Workflow file for this run
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
name: Release on Version Change | |
on: | |
pull_request: | |
branches: [ main ] | |
paths: | |
- "databend_py/VERSION" | |
jobs: | |
release: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v3 | |
- name: Set up Python | |
uses: actions/setup-python@v3 | |
with: | |
python-version: 3.9 | |
- name: Install Dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install setuptools wheel twine | |
- name: Determine Version Change | |
run: | | |
export VERSION=$(cat databend_py/VERSION) | |
- name: Release Package and Tag | |
env: | |
TWINE_USERNAME: ${{ secrets.TWINE_USERNAME }} | |
TWINE_PASSWORD: ${{ secrets.TWINE_PASSWORD }} | |
run: | | |
export VERSION=$(cat databend_py/VERSION) | |
git config user.name "hantmac" | |
git config user.email "[email protected]" | |
git tag -a "v$VERSION" -m "Release Version $VERSION" | |
git push origin "v$VERSION" | |
python setup.py sdist bdist_wheel | |
echo "show user name:" | |
echo ${{ secrets.TWINE_USERNAME }} | |
twine upload -u ${{ secrets.TWINE_USERNAME }} -p ${{ secrets.TWINE_PASSWORD }} dist/* |