cd-pydgraph #9
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: cd-pydgraph | |
on: | |
workflow_dispatch: | |
inputs: | |
releasetag: | |
description: 'releasetag' | |
required: true | |
type: string | |
jobs: | |
pydgraph-build: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
ref: '${{ github.event.inputs.releasetag }}' | |
- name: Get Python Version | |
run: | | |
#!/bin/bash | |
PYTHON_VERSION=$({ [ -f .python-version ] && cat .python-version; }) | |
echo "PYTHON_VERSION=$PYTHON_VERSION" >> $GITHUB_ENV | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ env.PYTHON_VERSION }} | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
python -m pip install .[dev] | |
# use twine to upload to pypi | |
python -m pip install twine | |
- name: Verify that protobufs are checked in | |
run: | | |
python scripts/protogen.py | |
git diff --exit-code -- . | |
- name: Build pydgraph | |
run: | | |
rm -rf dist | |
# build binary wheel and a source tarball | |
python -m build | |
- name: Upload to PyPi | |
run: twine upload --username ${{ secrets.DGRAPH_PYPI_USERNAME }} --password ${{ secrets.DGRAPH_PYPI_PASSWORD }} dist/* |