2024-06-08 22:18:51 +00:00
|
|
|
name: Build Python Package
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: python-3.12.3-alpine3.19
|
|
|
|
steps:
|
|
|
|
- name: Create and activate virtual environment
|
|
|
|
run: |
|
|
|
|
python -m venv venv
|
2024-06-08 22:31:38 +00:00
|
|
|
. venv/bin/activate
|
2024-06-08 22:18:51 +00:00
|
|
|
|
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
|
|
|
source venv/bin/activate
|
|
|
|
pip install --upgrade pip
|
|
|
|
pip install setuptools discord.py
|
|
|
|
|
|
|
|
- name: Build the package
|
|
|
|
run: |
|
|
|
|
source venv/bin/activate
|
|
|
|
python setup.py sdist
|
|
|
|
|
|
|
|
- name: Archive the package
|
|
|
|
uses: actions/upload-artifact@v2
|
|
|
|
with:
|
|
|
|
name: dist
|
|
|
|
path: dist/*.tar.gz
|