-
Notifications
You must be signed in to change notification settings - Fork 19
69 lines (67 loc) · 1.89 KB
/
Copy pathrelease.yaml
File metadata and controls
69 lines (67 loc) · 1.89 KB
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
63
64
65
66
67
68
69
name: Build and Publish
on:
push:
tags:
- '*'
jobs:
build-package:
name: Build a package
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Set up Python 3.11
uses: actions/setup-python@v6
with:
python-version: "3.11"
- name: Install dependencies
run: pip install -r requirements-dev.txt
- name: Build a binary wheel
run: python -m build
- name: Create Wheel Artifacts
uses: actions/upload-artifact@v5
with:
path: "dist/*.whl"
name: weaviate-cli-wheel
retention-days: 30
gh-release:
name: Create a GitHub Release on new tags
needs: [build-package]
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Download build artifact to append to release
uses: actions/download-artifact@v6
with:
name: weaviate-cli-wheel
path: dist
- name: Release
uses: softprops/action-gh-release@v2
with:
generate_release_notes: true
draft: true
files: dist/*.whl
publish:
runs-on: ubuntu-latest
needs: [gh-release]
steps:
- name: Checkout
uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Set up Python 3.11
uses: actions/setup-python@v6
with:
python-version: "3.11"
- name: Install dependencies
run: pip install -r requirements-dev.txt
- name: Build a binary wheel
run: python -m build
- name: Publish distribution 📦 to PyPI on new tags
uses: pypa/gh-action-pypi-publish@release/v1
with:
verbose: true
password: ${{ secrets.PYPI_API_TOKEN }}