Update CDF validator to accept x.com as a valid Twitter URL. #825
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build and publish CDF validator | |
on: | |
pull_request: | |
push: | |
branches: | |
- master | |
- dev | |
- staging | |
jobs: | |
build-n-test: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest, windows-latest] | |
python-version: ["3.8", "3.9", "3.10"] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install . | |
- name: Test code source | |
run: | | |
civics_cdf_validator list | |
python setup.py test | |
# Source Github Action template | |
deploy: | |
needs: build-n-test | |
if: github.event_name == 'push' | |
runs-on: ubuntu-latest | |
environment: | |
name: pypi | |
url: https://pypi.org/p/civics-cdf-validator | |
permissions: | |
id-token: write | |
contents: read | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: '3.X' | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install setuptools wheel twine | |
- name: Build a binary wheel | |
run: | | |
python setup.py sdist bdist_wheel | |
- name: Publish dist to PyPi | |
uses: pypa/gh-action-pypi-publish@release/v1 | |