Skip to content

Update project settings pt3 #29

Update project settings pt3

Update project settings pt3 #29

Workflow file for this run

# -*- coding: utf-8 -*-
# Copyright (C) 2023 Benjamin Thomas Schwertfeger
# GitHub: https://github.com/btschwertfeger
#
# Workflow to apply pre-commit, build, test and upload the package
# to the test index of PyPI.
#
name: CI
on:
push:
branches: [master]
schedule:
- cron: "20 16 */7 * *"
release:
types: [created]
pull_request:
types: [opened, synchronize, reopened]
branches: ["**"]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
## ==========================================================================
## Checks the code logic, style and more
##
Pre-Commit:
uses: ./.github/workflows/_pre_commit.yaml
## ==========================================================================
## Discover vulnerabilities
##
CodeQL:
uses: ./.github/workflows/_codeql.yaml
## ==========================================================================
## Builds the package on multiple OS for multiple
## Python versions
##
Build:
needs: [Pre-Commit]
uses: ./.github/workflows/_build.yaml
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
python-version: ["3.11", "3.13"]
with:
os: ${{ matrix.os }}
python-version: ${{ matrix.python-version }}
## ==========================================================================
## Uploads the package to test.pypi.org on master if triggered by
## a regular commit/push.
##
UploadPyPI:
if: success() && github.actor == 'btschwertfeger' && github.ref == 'refs/heads/master'
needs: [Build, Pre-Commit, CodeQL]
name: Upload current development version to Test PyPI
uses: ./.github/workflows/_pypi_publish.yaml
secrets:
API_TOKEN: ${{ secrets.PYPI_API_TOKEN }}