Skip to content
This repository has been archived by the owner on Jan 5, 2023. It is now read-only.
Permalink

Comparing changes

This is a direct comparison between two commits made in this repository or its related repositories. View the default comparison for this range or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: ansible-community/molecule-azure
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 0228e9487c774dc517fe95e17c917e266559b887
Choose a base ref
..
head repository: ansible-community/molecule-azure
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: f9e7829c13747b79aee0cd865c877f8fb801d488
Choose a head ref
Showing with 23 additions and 12 deletions.
  1. +23 −12 .github/workflows/tox.yml
35 changes: 23 additions & 12 deletions .github/workflows/tox.yml
Original file line number Diff line number Diff line change
@@ -3,12 +3,14 @@ name: tox
on:
create: # is used for publishing to PyPI and TestPyPI
tags: # any tag regardless of its name, no branches
- "**"
push: # only publishes pushes to the main branch to TestPyPI
branches: # any integration branch but not tag
- "master"
tags-ignore:
- "**"
pull_request:
release:
types:
- published # It seems that you can publish directly without creating
schedule:
- cron: 1 0 * * * # Run daily at 0:01 UTC

@@ -23,10 +25,16 @@ jobs:
- tox_env: lint
- tox_env: py36
PREFIX: PYTEST_REQPASS=2
- tox_env: py36-devel
PREFIX: PYTEST_REQPASS=2
- tox_env: py37
PREFIX: PYTEST_REQPASS=2
- tox_env: py38
PREFIX: PYTEST_REQPASS=2
- tox_env: py39
PREFIX: PYTEST_REQPASS=2
- tox_env: py39-devel
PREFIX: PYTEST_REQPASS=2
- tox_env: packaging
steps:
- uses: actions/checkout@v1
@@ -76,23 +84,29 @@ jobs:
- name: Check out src from Git
uses: actions/checkout@v2
with:
# Get shallow Git history (default) for tag creation events
# Get shallow Git history (default) for release events
# but have a complete clone for any other workflows.
# Both options fetch tags but since we're going to remove
# one from HEAD in non-create-tag workflows, we need full
# history for them.
fetch-depth: >-
${{
(
github.event_name == 'create' &&
github.event.ref_type == 'tag'
(
github.event_name == 'create' &&
github.event.ref_type == 'tag'
) ||
github.event_name == 'release'
) &&
1 || 0
}}
- name: Drop Git tags from HEAD for non-tag-create events
- name: Drop Git tags from HEAD for non-tag-create and non-release events
if: >-
github.event_name != 'create' ||
github.event.ref_type != 'tag'
(
github.event_name != 'create' ||
github.event.ref_type != 'tag'
) &&
github.event_name != 'release'
run: >-
git tag --points-at HEAD
|
@@ -117,10 +131,7 @@ jobs:
repository_url: https://test.pypi.org/legacy/
- name: Publish to pypi.org
if: >- # "create" workflows run separately from "push" & "pull_request"
github.event_name == 'create' &&
github.event.ref_type == 'tag'
github.event_name == 'release'
uses: pypa/gh-action-pypi-publish@master
with:
password: ${{ secrets.pypi_password }}
# No need to publish to quay.io from here as they do it when a new tag
# is pushed on git.