2024年6月7日 更新一下03 #86
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: Publish Python 🐍 distributions 📦 to PyPI | |
on: | |
push: | |
branches: | |
- main | |
# schedule: | |
# - cron: '0 4 */1 * *' | |
jobs: | |
build: | |
name: Publish Python 🐍 distributions 📦 to PyPI | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up Python 3.9 | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.9 | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install twine | |
- name: Build distributions | |
run: | | |
python setup.py sdist bdist_wheel | |
- name: Publish distribution 📦 to PyPI | |
uses: pypa/gh-action-pypi-publish@main | |
with: | |
user: __token__ | |
password: ${{ secrets.pypi_password }} | |
# repository_url: https://pypi.org/legacy/ | |