更新build完成publish
Build and Publish / Run (push) Has been cancelled Details

This commit is contained in:
cxykevin 2024-04-16 21:47:07 +08:00
parent e46630e58b
commit c6a7923eeb
1 changed files with 10 additions and 3 deletions

View File

@ -5,6 +5,9 @@ on: [push]
jobs: jobs:
Run: Run:
runs-on: ubuntu-latest runs-on: ubuntu-latest
environment:
name: pypi
url: https://pypi.org/p/<your-pypi-project-name>
steps: steps:
- name: Info - name: Info
run: echo "OS=${{ runner.os }} NAME=${{ gitea.event_name }} REPO=${{ gitea.repository }} BRANCH=${{ gitea.ref }} ST=${{ job.status }}" run: echo "OS=${{ runner.os }} NAME=${{ gitea.event_name }} REPO=${{ gitea.repository }} BRANCH=${{ gitea.ref }} ST=${{ job.status }}"
@ -16,15 +19,19 @@ jobs:
echo "deb http://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-backports main contrib non-free">>/etc/apt/sources.list echo "deb http://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-backports main contrib non-free">>/etc/apt/sources.list
echo "deb https://security.debian.org/debian-security bullseye-security main contrib non-free">>/etc/apt/sources.list echo "deb https://security.debian.org/debian-security bullseye-security main contrib non-free">>/etc/apt/sources.list
cat /etc/apt/sources.list cat /etc/apt/sources.list
echo "--- uddate source ---" echo "--- update source ---"
apt-get update apt-get update
- name: Prepare Python - name: Prepare Python
run: | run: |
apt-get install python3-pip -y apt-get install python3-pip -y
python3 -m pip install setuptools python3 -m pip install setuptools wheel twine
- name: CheckOut - name: CheckOut
uses: http://hmtsai.cn:3000/actions/checkout@v4 uses: http://hmtsai.cn:3000/actions/checkout@v4
- name: Build - name: Build
run: python3 setup.py build run: python3 setup.py build
- name: Publish - name: Publish
run: echo "Publish..." env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
run: |
twine upload dist/*