-
Notifications
You must be signed in to change notification settings - Fork 518
62 lines (59 loc) · 1.82 KB
/
publish_dev_package.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
name: Publish package to TestPyPI
# on:
# push:
# branches:
# - 'main'
# paths:
# - 'gptcache/**'
# - '!**.md'
# - '.github/workflows/publish_dev_package.yaml'
# pull_request:
# branches:
# - main
# paths:
# - '.github/workflows/publish_dev_package.yaml'
on:
workflow_dispatch:
schedule:
# * is a special character in YAML so you have to quote this string
# ┌───────────── minute (0 - 59)
# │ ┌───────────── hour (0 - 23)
# │ │ ┌───────────── day of the month (1 - 31)
# │ │ │ ┌───────────── month (1 - 12 or JAN-DEC)
# │ │ │ │ ┌───────────── day of the week (0 - 6 or SUN-SAT)
# │ │ │ │ │
# │ │ │ │ │
# │ │ │ │ │
- cron: '30 9 * * 1,4'
jobs:
build-and-publish-dev:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@master
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: 3.8
# - name: Get history and tags for SCM versioning
# run: |
# git fetch --prune --unshallow
# git fetch --depth=1 origin +refs/tags/*:refs/tags/*
- name: Install pypi/build
run: >-
python -m
pip install
build
--user
- name: Build a binary wheel and a source tarball
run: >-
python -m
build
--sdist
--wheel
--outdir dist/
.
- name: Publish distribution 📦 to Test PyPI
uses: pypa/gh-action-pypi-publish@master
with:
password: ${{ secrets.PYPI_TEST_TOKEN }}
repository_url: https://test.pypi.org/legacy/