mirror of
https://github.com/zoriya/guessit.git
synced 2026-06-02 10:38:01 +00:00
ci: drop TravisCI and ReadTheDocs, replaced by Github Actions and mkdocs
This commit is contained in:
@@ -0,0 +1,97 @@
|
||||
name: ci
|
||||
on:
|
||||
push: ~
|
||||
pull_request: ~
|
||||
jobs:
|
||||
build:
|
||||
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
python-version: [ 2.7, 3.5, 3.6, 3.7, 3.8 ]
|
||||
|
||||
steps:
|
||||
- name: Setup python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Git User config
|
||||
run: |
|
||||
git config --global user.email "action@github.com"
|
||||
git config --global user.name "github-actions"
|
||||
|
||||
- name: Install Dependencies
|
||||
run: |
|
||||
pip install pip --upgrade
|
||||
pip install -e .[dev,test] --upgrade
|
||||
pip install pytest --upgrade
|
||||
pip install coveralls
|
||||
pytest --version
|
||||
|
||||
- run: pylint guessit
|
||||
if: matrix.python-version != '3.9'
|
||||
|
||||
- run: coverage run --source=guessit setup.py test
|
||||
|
||||
- run: python setup.py build
|
||||
|
||||
- name: Coveralls
|
||||
run: coveralls
|
||||
env:
|
||||
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
|
||||
|
||||
release:
|
||||
if: ${{ github.ref == 'refs/heads/master' && github.event_name == 'push' }}
|
||||
needs: build
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
python-version: [ 3.8 ]
|
||||
|
||||
steps:
|
||||
- name: Setup python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Git User config
|
||||
run: |
|
||||
git config --global user.email "action@github.com"
|
||||
git config --global user.name "github-actions"
|
||||
|
||||
- name: Install Dependencies
|
||||
run: pip install -r requirements-dev.txt
|
||||
|
||||
- name: Install python-semantic-release
|
||||
run: pip install python-semantic-release
|
||||
|
||||
- name: Publish release
|
||||
run: semantic-release -v DEBUG publish
|
||||
env:
|
||||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}
|
||||
|
||||
- name: Merge master to develop
|
||||
# uses: robotology/gh-action-nightly-merge@v1.3.1 # Wait PR merge https://github.com/robotology/gh-action-nightly-merge/pull/5
|
||||
uses: Toilal/gh-action-nightly-merge@master
|
||||
with:
|
||||
stable_branch: 'master'
|
||||
development_branch: 'develop'
|
||||
allow_ff: true
|
||||
user_name: github-actions
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
@@ -0,0 +1,15 @@
|
||||
name: mkdocs
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
jobs:
|
||||
deploy:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: 3.x
|
||||
- run: pip install mkdocs-material
|
||||
- run: mkdocs gh-deploy --force
|
||||
Reference in New Issue
Block a user