summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Wittig <max.wittig95@gmail.com>2019-12-19 19:04:41 +0100
committerMax Wittig <max.wittig95@gmail.com>2020-01-02 12:03:12 +0100
commitf5b43a01478bb06c80baf44363de1cdca64109f6 (patch)
treecbe451d47192b5d7e5d8b1f84885b744c46da336
parentbb657377ef39ed4ee924a20672b34e36016d51b2 (diff)
downloadgitlab-chore/ci-github-actions.tar.gz
test: update lint.ymlchore/ci-github-actions
-rw-r--r--.github/workflows/lint.yml4
-rw-r--r--.github/workflows/main.yml73
-rw-r--r--.travis.yml69
3 files changed, 63 insertions, 83 deletions
diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml
index 01da774..c2d2dd2 100644
--- a/.github/workflows/lint.yml
+++ b/.github/workflows/lint.yml
@@ -13,9 +13,9 @@ jobs:
npm config set prefix "${HOME}/.npm-packages"
export PATH="$PATH:$NPM_PACKAGES/bin"
npm install -g @commitlint/cli @commitlint/config-conventional
- 'echo "module.exports = {extends: [\"@commitlint/config-conventional\"]}" > commitlint.config.js'
+ echo "module.exports = {extends: [\"@commitlint/config-conventional\"]}" > commitlint.config.js
npx commitlint --from=origin/master
- name: Run black
run: |
pip3 install --pre black==19.10b0
- black --check .
+ python3 -m black --check .
diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml
index 83dbb28..f9dea53 100644
--- a/.github/workflows/main.yml
+++ b/.github/workflows/main.yml
@@ -1,22 +1,71 @@
name: CI
-on:
- push:
- branches:
- - master
-
-strategy:
- matrix:
- environment: ["py36", "py37", "docs", "py_func_v4", "cli_func_v4"]
+on: [push]
jobs:
- build:
+ test-3-6:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v1
+ - uses: actions/setup-python@v1
+ with:
+ python-version: "3.6"
+ - name: Test py36
+ run: |
+ pip3 install tox
+ python3 -m tox -e py36
+ test-3-7:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- - name: Test CLI func
+ - uses: actions/setup-python@v1
+ with:
+ python-version: "3.7"
+ - name: Test py37
run: |
pip3 install tox
- tox -e ${ENVIRONMENT}
+ python3 -m tox -e py37
+ test-3-8:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v1
+ - uses: actions/setup-python@v1
with:
- environment: ${{ matrix.environment }}
+ python-version: "3.8"
+ - name: Test py38
+ run: |
+ pip3 install tox
+ python3 -m tox -e py38
+ test-docs:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v1
+ - uses: actions/setup-python@v1
+ with:
+ python-version: "3.8"
+ - name: Test py38
+ run: |
+ pip3 install tox
+ python3 -m tox -e docs
+ test-py_func_v4:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v1
+ - uses: actions/setup-python@v1
+ with:
+ python-version: "3.8"
+ - name: Test py38
+ run: |
+ pip3 install tox
+ python3 -m tox -e py_func_v4
+ test-cli_func_v4:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v1
+ - uses: actions/setup-python@v1
+ with:
+ python-version: "3.8"
+ - name: Test py38
+ run: |
+ pip3 install tox
+ python3 -m tox -e cli_func_v4
diff --git a/.travis.yml b/.travis.yml
deleted file mode 100644
index 83d2d33..0000000
--- a/.travis.yml
+++ /dev/null
@@ -1,69 +0,0 @@
-sudo: required
-services:
- - docker
-language: python
-
-git:
- depth: false
-
-stages:
- - lint
- - test
-
-jobs:
- include:
- - stage: lint
- name: commitlint
- script:
- - npm install -g @commitlint/cli @commitlint/config-conventional
- - 'echo "module.exports = {extends: [\"@commitlint/config-conventional\"]}" > commitlint.config.js'
- - npx commitlint --from=origin/master
- - stage: lint
- name: black_lint
- dist: bionic
- python: 3.8
- script:
- - pip3 install -U --pre black
- - black --check .
- - stage: test
- name: cli_func_v4
- dist: bionic
- python: 3.8
- script:
- - pip3 install tox
- - tox -e cli_func_v4
- - stage: test
- name: py_func_v4
- dist: bionic
- python: 3.8
- script:
- - pip3 install tox
- - tox -e py_func_v4
- - stage: test
- name: docs
- dist: bionic
- python: 3.8
- script:
- - pip3 install tox
- - tox -e docs
- - stage: test
- name: py36
- python: 3.6
- dist: bionic
- script:
- - pip3 install tox
- - tox -e py36
- - stage: test
- name: py37
- dist: bionic
- python: 3.7
- script:
- - pip3 install tox
- - tox -e py37
- - stage: test
- dist: bionic
- name: py38
- python: 3.8
- script:
- - pip3 install tox
- - tox -e py38