Skip to content

Commit

Permalink
fix(publish): Fixes workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
mcaulifn committed Jan 26, 2021
1 parent f2d12e7 commit 8617f42
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 46 deletions.
32 changes: 0 additions & 32 deletions .github/workflows/build.yml

This file was deleted.

25 changes: 12 additions & 13 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,14 @@ name: "CodeQL"

on:
push:
branches: [master, ]
branches:
- master
- main
pull_request:
# The branches below must be a subset of the branches above
branches: [master]
branches:
- master
- main
schedule:
- cron: '0 14 * * 2'

Expand All @@ -14,25 +18,20 @@ jobs:
name: Analyse
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
language: [ 'python' ]

steps:
- name: Checkout repository
uses: actions/[email protected]
with:
# We must fetch at least the immediate parents so that if this is
# a pull request then we can checkout the head.
fetch-depth: 2

# If this run was triggered by a pull request event, then checkout
# the head of the pull request instead of the merge commit.
- run: git checkout HEAD^2
if: ${{ github.event_name == 'pull_request' }}

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
# Override language selection by uncommenting this and choosing your languages
with:
languages: python
languages: ${{ matrix.language }}

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
Expand Down
27 changes: 27 additions & 0 deletions .github/workflows/pullrequest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,34 @@ on:
- "!*"

jobs:
build:
runs-on: ubuntu-latest
strategy:
max-parallel: 4
matrix:
python-version:
- 3.7
- 3.8
steps:
- uses: actions/[email protected]
- name: Set up Python ${{ matrix.python-version }}
uses: actions/[email protected]
with:
python-version: "${{ matrix.python-version }}"
- name: Run tox
run: |
python -m pip install --upgrade pip
pip install tox
tox -e py
- uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.xml
flags: unittests
name: pysolcast

deploy:
needs: [build, linting]
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ jobs:
password: ${{ secrets.test_pypi_password }}
repository_url: https://test.pypi.org/legacy/
- name: Publish distribution 📦 to PyPI
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@master
with:
user: __token__
Expand Down

0 comments on commit 8617f42

Please sign in to comment.