From 379452a635cdae4cb143b35fcfa98b9fdff73269 Mon Sep 17 00:00:00 2001 From: Robert Kaussow Date: Tue, 22 Aug 2023 21:49:57 +0200 Subject: [PATCH] ci: migrate to woodpecker (#287) --- .dictionary | 1 + .drone.jsonnet | 322 ----------------- .drone.yml | 342 ------------------ .github/settings.yml | 7 +- .markdownlint.yml | 6 + .woodpecker/build-container.yml | 74 ++++ .woodpecker/build-package.yml | 63 ++++ .woodpecker/docs.yml | 72 ++++ .woodpecker/lint.yml | 27 ++ .woodpecker/notify.yml | 26 ++ .woodpecker/test.yml | 30 ++ ...rfile.multiarch => Containerfile.multiarch | 0 README.md | 2 +- 13 files changed, 305 insertions(+), 667 deletions(-) create mode 100644 .dictionary delete mode 100644 .drone.jsonnet delete mode 100644 .drone.yml create mode 100644 .markdownlint.yml create mode 100644 .woodpecker/build-container.yml create mode 100644 .woodpecker/build-package.yml create mode 100644 .woodpecker/docs.yml create mode 100644 .woodpecker/lint.yml create mode 100644 .woodpecker/notify.yml create mode 100644 .woodpecker/test.yml rename Dockerfile.multiarch => Containerfile.multiarch (100%) diff --git a/.dictionary b/.dictionary new file mode 100644 index 0000000..c7f3e09 --- /dev/null +++ b/.dictionary @@ -0,0 +1 @@ +PyPi diff --git a/.drone.jsonnet b/.drone.jsonnet deleted file mode 100644 index 388185e..0000000 --- a/.drone.jsonnet +++ /dev/null @@ -1,322 +0,0 @@ -local PythonVersion(pyversion='3.7') = { - name: 'python' + std.strReplace(pyversion, '.', '') + '-pytest', - image: 'python:' + pyversion, - environment: { - PY_COLORS: 1, - }, - commands: [ - 'pip install poetry poetry-dynamic-versioning -qq', - 'poetry install', - 'poetry version', - 'poetry run git-batch --help', - ], - depends_on: [ - 'fetch', - ], -}; - -local PipelineLint = { - kind: 'pipeline', - name: 'lint', - platform: { - os: 'linux', - arch: 'amd64', - }, - steps: [ - { - name: 'check-format', - image: 'python:3.11', - environment: { - PY_COLORS: 1, - }, - commands: [ - 'git fetch -tq', - 'pip install poetry poetry-dynamic-versioning -qq', - 'poetry install', - 'poetry run yapf -dr ./gitbatch', - ], - }, - { - name: 'check-coding', - image: 'python:3.11', - environment: { - PY_COLORS: 1, - }, - commands: [ - 'git fetch -tq', - 'pip install poetry poetry-dynamic-versioning -qq', - 'poetry install', - 'poetry run ruff ./gitbatch', - ], - }, - ], - trigger: { - ref: ['refs/heads/main', 'refs/tags/**', 'refs/pull/**'], - }, -}; - -local PipelineTest = { - kind: 'pipeline', - name: 'test', - platform: { - os: 'linux', - arch: 'amd64', - }, - steps: [ - { - name: 'fetch', - image: 'python:3.11', - commands: [ - 'git fetch -tq', - ], - }, - PythonVersion(pyversion='3.7'), - PythonVersion(pyversion='3.8'), - PythonVersion(pyversion='3.9'), - PythonVersion(pyversion='3.10'), - PythonVersion(pyversion='3.11'), - ], - depends_on: [ - 'lint', - ], - trigger: { - ref: ['refs/heads/main', 'refs/tags/**', 'refs/pull/**'], - }, -}; - -local PipelineBuildPackage = { - kind: 'pipeline', - name: 'build-package', - platform: { - os: 'linux', - arch: 'amd64', - }, - steps: [ - { - name: 'build', - image: 'python:3.11', - commands: [ - 'git fetch -tq', - 'pip install poetry poetry-dynamic-versioning -qq', - 'poetry build', - ], - }, - { - name: 'checksum', - image: 'alpine', - commands: [ - 'cd dist/ && sha256sum * > ../sha256sum.txt', - ], - }, - { - name: 'changelog-generate', - image: 'thegeeklab/git-chglog', - commands: [ - 'git fetch -tq', - 'git-chglog --no-color --no-emoji -o CHANGELOG.md ${DRONE_TAG:---next-tag unreleased unreleased}', - ], - }, - { - name: 'changelog-format', - image: 'thegeeklab/alpine-tools', - commands: [ - 'prettier CHANGELOG.md', - 'prettier -w CHANGELOG.md', - ], - }, - { - name: 'publish-github', - image: 'plugins/github-release', - settings: { - overwrite: true, - api_key: { from_secret: 'github_token' }, - files: ['dist/*', 'sha256sum.txt'], - title: '${DRONE_TAG}', - note: 'CHANGELOG.md', - }, - when: { - ref: ['refs/tags/**'], - }, - }, - { - name: 'publish-pypi', - image: 'python:3.11', - commands: [ - 'git fetch -tq', - 'pip install poetry poetry-dynamic-versioning -qq', - 'poetry publish -n', - ], - environment: { - POETRY_HTTP_BASIC_PYPI_USERNAME: { from_secret: 'pypi_username' }, - POETRY_HTTP_BASIC_PYPI_PASSWORD: { from_secret: 'pypi_password' }, - }, - when: { - ref: ['refs/tags/**'], - }, - }, - ], - depends_on: [ - 'test', - ], - trigger: { - ref: ['refs/heads/main', 'refs/tags/**', 'refs/pull/**'], - }, -}; - -local PipelineBuildContainer = { - kind: 'pipeline', - name: 'build-container', - platform: { - os: 'linux', - arch: 'amd64', - }, - steps: [ - { - name: 'build', - image: 'python:3.11', - commands: [ - 'git fetch -tq', - 'pip install poetry poetry-dynamic-versioning -qq', - 'poetry build', - ], - }, - { - name: 'dryrun', - image: 'thegeeklab/drone-docker-buildx:23', - settings: { - dry_run: true, - dockerfile: 'Dockerfile.multiarch', - repo: 'thegeeklab/${DRONE_REPO_NAME}', - platforms: [ - 'linux/amd64', - 'linux/arm64', - ], - provenance: false, - }, - depends_on: ['build'], - when: { - ref: ['refs/pull/**'], - }, - }, - { - name: 'publish-dockerhub', - image: 'thegeeklab/drone-docker-buildx:23', - settings: { - auto_tag: true, - dockerfile: 'Dockerfile.multiarch', - repo: 'thegeeklab/${DRONE_REPO_NAME}', - username: { from_secret: 'docker_username' }, - password: { from_secret: 'docker_password' }, - platforms: [ - 'linux/amd64', - 'linux/arm64', - ], - provenance: false, - }, - when: { - ref: ['refs/heads/main', 'refs/tags/**'], - }, - depends_on: ['dryrun'], - }, - { - name: 'publish-quay', - image: 'thegeeklab/drone-docker-buildx:23', - settings: { - auto_tag: true, - dockerfile: 'Dockerfile.multiarch', - registry: 'quay.io', - repo: 'quay.io/thegeeklab/${DRONE_REPO_NAME}', - username: { from_secret: 'quay_username' }, - password: { from_secret: 'quay_password' }, - platforms: [ - 'linux/amd64', - 'linux/arm64', - ], - provenance: false, - }, - when: { - ref: ['refs/heads/main', 'refs/tags/**'], - }, - depends_on: ['dryrun'], - }, - ], - depends_on: [ - 'test', - ], - trigger: { - ref: ['refs/heads/main', 'refs/tags/**', 'refs/pull/**'], - }, -}; - -local PipelineNotifications = { - kind: 'pipeline', - name: 'notifications', - platform: { - os: 'linux', - arch: 'amd64', - }, - steps: [ - { - name: 'pushrm-dockerhub', - image: 'chko/docker-pushrm:1', - environment: { - DOCKER_PASS: { - from_secret: 'docker_password', - }, - DOCKER_USER: { - from_secret: 'docker_username', - }, - PUSHRM_FILE: 'README.md', - PUSHRM_SHORT: 'GitHub release notification bot', - PUSHRM_TARGET: 'thegeeklab/${DRONE_REPO_NAME}', - }, - when: { - status: ['success'], - }, - }, - { - name: 'pushrm-quay', - image: 'chko/docker-pushrm:1', - environment: { - APIKEY__QUAY_IO: { - from_secret: 'quay_token', - }, - PUSHRM_FILE: 'README.md', - PUSHRM_TARGET: 'quay.io/thegeeklab/${DRONE_REPO_NAME}', - }, - when: { - status: ['success'], - }, - }, - { - name: 'matrix', - image: 'thegeeklab/drone-matrix', - settings: { - homeserver: { from_secret: 'matrix_homeserver' }, - roomid: { from_secret: 'matrix_roomid' }, - template: 'Status: **{{ .Build.Status }}**
Build: [{{ .Repo.Owner }}/{{ .Repo.Name }}]({{ .Build.Link }}){{ if .Build.Branch }} ({{ .Build.Branch }}){{ end }} by {{ .Commit.Author }}
Message: {{ .Commit.Message.Title }}', - username: { from_secret: 'matrix_username' }, - password: { from_secret: 'matrix_password' }, - }, - when: { - status: ['success', 'failure'], - }, - }, - ], - depends_on: [ - 'build-package', - 'build-container', - ], - trigger: { - ref: ['refs/heads/main', 'refs/tags/**'], - status: ['success', 'failure'], - }, -}; - -[ - PipelineLint, - PipelineTest, - PipelineBuildPackage, - PipelineBuildContainer, - PipelineNotifications, -] diff --git a/.drone.yml b/.drone.yml deleted file mode 100644 index 6fea3a9..0000000 --- a/.drone.yml +++ /dev/null @@ -1,342 +0,0 @@ ---- -kind: pipeline -name: lint - -platform: - os: linux - arch: amd64 - -steps: - - name: check-format - image: python:3.11 - commands: - - git fetch -tq - - pip install poetry poetry-dynamic-versioning -qq - - poetry install - - poetry run yapf -dr ./gitbatch - environment: - PY_COLORS: 1 - - - name: check-coding - image: python:3.11 - commands: - - git fetch -tq - - pip install poetry poetry-dynamic-versioning -qq - - poetry install - - poetry run ruff ./gitbatch - environment: - PY_COLORS: 1 - -trigger: - ref: - - refs/heads/main - - refs/tags/** - - refs/pull/** - ---- -kind: pipeline -name: test - -platform: - os: linux - arch: amd64 - -steps: - - name: fetch - image: python:3.11 - commands: - - git fetch -tq - - - name: python37-pytest - image: python:3.7 - commands: - - pip install poetry poetry-dynamic-versioning -qq - - poetry install - - poetry version - - poetry run git-batch --help - environment: - PY_COLORS: 1 - depends_on: - - fetch - - - name: python38-pytest - image: python:3.8 - commands: - - pip install poetry poetry-dynamic-versioning -qq - - poetry install - - poetry version - - poetry run git-batch --help - environment: - PY_COLORS: 1 - depends_on: - - fetch - - - name: python39-pytest - image: python:3.9 - commands: - - pip install poetry poetry-dynamic-versioning -qq - - poetry install - - poetry version - - poetry run git-batch --help - environment: - PY_COLORS: 1 - depends_on: - - fetch - - - name: python310-pytest - image: python:3.10 - commands: - - pip install poetry poetry-dynamic-versioning -qq - - poetry install - - poetry version - - poetry run git-batch --help - environment: - PY_COLORS: 1 - depends_on: - - fetch - - - name: python311-pytest - image: python:3.11 - commands: - - pip install poetry poetry-dynamic-versioning -qq - - poetry install - - poetry version - - poetry run git-batch --help - environment: - PY_COLORS: 1 - depends_on: - - fetch - -trigger: - ref: - - refs/heads/main - - refs/tags/** - - refs/pull/** - -depends_on: - - lint - ---- -kind: pipeline -name: build-package - -platform: - os: linux - arch: amd64 - -steps: - - name: build - image: python:3.11 - commands: - - git fetch -tq - - pip install poetry poetry-dynamic-versioning -qq - - poetry build - - - name: checksum - image: alpine - commands: - - cd dist/ && sha256sum * > ../sha256sum.txt - - - name: changelog-generate - image: thegeeklab/git-chglog - commands: - - git fetch -tq - - git-chglog --no-color --no-emoji -o CHANGELOG.md ${DRONE_TAG:---next-tag unreleased unreleased} - - - name: changelog-format - image: thegeeklab/alpine-tools - commands: - - prettier CHANGELOG.md - - prettier -w CHANGELOG.md - - - name: publish-github - image: plugins/github-release - settings: - api_key: - from_secret: github_token - files: - - dist/* - - sha256sum.txt - note: CHANGELOG.md - overwrite: true - title: ${DRONE_TAG} - when: - ref: - - refs/tags/** - - - name: publish-pypi - image: python:3.11 - commands: - - git fetch -tq - - pip install poetry poetry-dynamic-versioning -qq - - poetry publish -n - environment: - POETRY_HTTP_BASIC_PYPI_PASSWORD: - from_secret: pypi_password - POETRY_HTTP_BASIC_PYPI_USERNAME: - from_secret: pypi_username - when: - ref: - - refs/tags/** - -trigger: - ref: - - refs/heads/main - - refs/tags/** - - refs/pull/** - -depends_on: - - test - ---- -kind: pipeline -name: build-container - -platform: - os: linux - arch: amd64 - -steps: - - name: build - image: python:3.11 - commands: - - git fetch -tq - - pip install poetry poetry-dynamic-versioning -qq - - poetry build - - - name: dryrun - image: thegeeklab/drone-docker-buildx:23 - settings: - dockerfile: Dockerfile.multiarch - dry_run: true - platforms: - - linux/amd64 - - linux/arm64 - provenance: false - repo: thegeeklab/${DRONE_REPO_NAME} - when: - ref: - - refs/pull/** - depends_on: - - build - - - name: publish-dockerhub - image: thegeeklab/drone-docker-buildx:23 - settings: - auto_tag: true - dockerfile: Dockerfile.multiarch - password: - from_secret: docker_password - platforms: - - linux/amd64 - - linux/arm64 - provenance: false - repo: thegeeklab/${DRONE_REPO_NAME} - username: - from_secret: docker_username - when: - ref: - - refs/heads/main - - refs/tags/** - depends_on: - - dryrun - - - name: publish-quay - image: thegeeklab/drone-docker-buildx:23 - settings: - auto_tag: true - dockerfile: Dockerfile.multiarch - password: - from_secret: quay_password - platforms: - - linux/amd64 - - linux/arm64 - provenance: false - registry: quay.io - repo: quay.io/thegeeklab/${DRONE_REPO_NAME} - username: - from_secret: quay_username - when: - ref: - - refs/heads/main - - refs/tags/** - depends_on: - - dryrun - -trigger: - ref: - - refs/heads/main - - refs/tags/** - - refs/pull/** - -depends_on: - - test - ---- -kind: pipeline -name: notifications - -platform: - os: linux - arch: amd64 - -steps: - - name: pushrm-dockerhub - image: chko/docker-pushrm:1 - environment: - DOCKER_PASS: - from_secret: docker_password - DOCKER_USER: - from_secret: docker_username - PUSHRM_FILE: README.md - PUSHRM_SHORT: GitHub release notification bot - PUSHRM_TARGET: thegeeklab/${DRONE_REPO_NAME} - when: - status: - - success - - - name: pushrm-quay - image: chko/docker-pushrm:1 - environment: - APIKEY__QUAY_IO: - from_secret: quay_token - PUSHRM_FILE: README.md - PUSHRM_TARGET: quay.io/thegeeklab/${DRONE_REPO_NAME} - when: - status: - - success - - - name: matrix - image: thegeeklab/drone-matrix - settings: - homeserver: - from_secret: matrix_homeserver - password: - from_secret: matrix_password - roomid: - from_secret: matrix_roomid - template: "Status: **{{ .Build.Status }}**
Build: [{{ .Repo.Owner }}/{{ .Repo.Name }}]({{ .Build.Link }}){{ if .Build.Branch }} ({{ .Build.Branch }}){{ end }} by {{ .Commit.Author }}
Message: {{ .Commit.Message.Title }}" - username: - from_secret: matrix_username - when: - status: - - success - - failure - -trigger: - ref: - - refs/heads/main - - refs/tags/** - status: - - success - - failure - -depends_on: - - build-package - - build-container - ---- -kind: signature -hmac: 3788e000ef7c4f80a3d97a4b903fe56748673e9eec42f969d629e8f600afdd53 - -... diff --git a/.github/settings.yml b/.github/settings.yml index 761652a..b05d68f 100644 --- a/.github/settings.yml +++ b/.github/settings.yml @@ -51,7 +51,10 @@ branches: required_status_checks: strict: false contexts: - - continuous-integration/drone/pr - enforce_admins: true + - ci/woodpecker/pr/test + - ci/woodpecker/pr/build-package + - ci/woodpecker/pr/build-container + - ci/woodpecker/pr/docs + enforce_admins: false required_linear_history: true restrictions: null diff --git a/.markdownlint.yml b/.markdownlint.yml new file mode 100644 index 0000000..b59a114 --- /dev/null +++ b/.markdownlint.yml @@ -0,0 +1,6 @@ +--- +default: True +MD013: False +MD041: False +MD004: + style: dash diff --git a/.woodpecker/build-container.yml b/.woodpecker/build-container.yml new file mode 100644 index 0000000..0b7d389 --- /dev/null +++ b/.woodpecker/build-container.yml @@ -0,0 +1,74 @@ +--- +when: + - event: [pull_request, tag] + - event: [push, manual] + branch: + - ${CI_REPO_DEFAULT_BRANCH} + +steps: + build: + image: docker.io/library/python:3.11 + commands: + - git fetch -tq + - pip install poetry poetry-dynamic-versioning -qq + - poetry build + + dryrun: + image: quay.io/thegeeklab/wp-docker-buildx:1 + settings: + containerfile: Containerfile.multiarch + dry_run: true + platforms: + - linux/amd64 + - linux/arm64 + provenance: false + repo: ${CI_REPO} + when: + - event: [pull_request] + + publish-dockerhub: + group: container + image: quay.io/thegeeklab/wp-docker-buildx:1 + settings: + auto_tag: true + containerfile: Containerfile.multiarch + password: + from_secret: docker_password + platforms: + - linux/amd64 + - linux/arm64 + provenance: false + repo: ${CI_REPO} + username: + from_secret: docker_username + when: + - event: [tag] + - event: [push, manual] + branch: + - ${CI_REPO_DEFAULT_BRANCH} + + publish-quay: + group: container + image: quay.io/thegeeklab/wp-docker-buildx:1 + settings: + auto_tag: true + containerfile: Containerfile.multiarch + password: + from_secret: quay_password + platforms: + - linux/amd64 + - linux/arm64 + provenance: false + registry: quay.io + repo: quay.io/${CI_REPO} + username: + from_secret: quay_username + when: + - event: [tag] + - event: [push, manual] + branch: + - ${CI_REPO_DEFAULT_BRANCH} + +depends_on: + - lint + - test diff --git a/.woodpecker/build-package.yml b/.woodpecker/build-package.yml new file mode 100644 index 0000000..cf68ab1 --- /dev/null +++ b/.woodpecker/build-package.yml @@ -0,0 +1,63 @@ +--- +when: + - event: [pull_request, tag] + - event: [push, manual] + branch: + - ${CI_REPO_DEFAULT_BRANCH} + +steps: + build: + image: docker.io/library/python:3.11 + commands: + - git fetch -tq + - pip install poetry poetry-dynamic-versioning -qq + - poetry build + + checksum: + image: quay.io/thegeeklab/alpine-tools + commands: + - cd dist/ && sha256sum * > ../sha256sum.txt + + changelog-generate: + image: quay.io/thegeeklab/git-chglog + commands: + - git fetch -tq + - git-chglog --no-color --no-emoji -o CHANGELOG.md ${CI_COMMIT_TAG:---next-tag unreleased unreleased} + + changelog-format: + image: quay.io/thegeeklab/alpine-tools + commands: + - prettier CHANGELOG.md + - prettier -w CHANGELOG.md + + publish-github: + image: docker.io/plugins/github-release + settings: + api_key: + from_secret: github_token + files: + - dist/* + - sha256sum.txt + note: CHANGELOG.md + overwrite: true + title: ${CI_COMMIT_TAG} + when: + - event: [tag] + + publish-pypi: + image: docker.io/library/python:3.11 + secrets: + - source: pypi_password + target: POETRY_HTTP_BASIC_PYPI_PASSWORD + - source: pypi_username + target: POETRY_HTTP_BASIC_PYPI_USERNAME + commands: + - git fetch -tq + - pip install poetry poetry-dynamic-versioning -qq + - poetry publish -n + when: + - event: [tag] + +depends_on: + - lint + - test diff --git a/.woodpecker/docs.yml b/.woodpecker/docs.yml new file mode 100644 index 0000000..5ffdcab --- /dev/null +++ b/.woodpecker/docs.yml @@ -0,0 +1,72 @@ +--- +when: + - event: [pull_request, tag] + - event: [push, manual] + branch: + - ${CI_REPO_DEFAULT_BRANCH} + +steps: + markdownlint: + image: quay.io/thegeeklab/markdownlint-cli + commands: + - markdownlint 'README.md' 'CONTRIBUTING.md' + + spellcheck: + image: quay.io/thegeeklab/alpine-tools + commands: + - spellchecker --files '_docs/**/*.md' 'README.md' 'CONTRIBUTING.md' -d .dictionary -p spell indefinite-article syntax-urls + environment: + FORCE_COLOR: "true" + NPM_CONFIG_LOGLEVEL: "error" + + publish: + image: quay.io/thegeeklab/wp-git-action + settings: + action: + - pages + author_email: bot@thegeeklab.de + author_name: thegeeklab-bot + branch: docs + message: "[skip ci] auto-update documentation" + netrc_password: + from_secret: github_token + pages_directory: _docs/ + when: + - event: [push, manual] + branch: + - ${CI_REPO_DEFAULT_BRANCH} + + pushrm-dockerhub: + image: docker.io/chko/docker-pushrm:1 + secrets: + - source: docker_password + target: DOCKER_PASS + - source: docker_username + target: DOCKER_USER + environment: + PUSHRM_FILE: README.md + PUSHRM_SHORT: Automate cloning a single branch from a list of repositories + PUSHRM_TARGET: ${CI_REPO} + when: + - event: [push, manual] + branch: + - ${CI_REPO_DEFAULT_BRANCH} + status: [success] + + pushrm-quay: + image: docker.io/chko/docker-pushrm:1 + secrets: + - source: quay_token + target: APIKEY__QUAY_IO + environment: + PUSHRM_FILE: README.md + PUSHRM_TARGET: quay.io/${CI_REPO} + when: + - event: [push, manual] + branch: + - ${CI_REPO_DEFAULT_BRANCH} + status: [success] + +depends_on: + - build-package + - build-container diff --git a/.woodpecker/lint.yml b/.woodpecker/lint.yml new file mode 100644 index 0000000..73330ff --- /dev/null +++ b/.woodpecker/lint.yml @@ -0,0 +1,27 @@ +--- +when: + - event: [pull_request, tag] + - event: [push, manual] + branch: + - ${CI_REPO_DEFAULT_BRANCH} + +steps: + check-format: + image: docker.io/library/python:3.11 + commands: + - git fetch -tq + - pip install poetry poetry-dynamic-versioning -qq + - poetry install + - poetry run yapf -dr ./gitbatch + environment: + PY_COLORS: "1" + + check-coding: + image: docker.io/library/python:3.11 + commands: + - git fetch -tq + - pip install poetry poetry-dynamic-versioning -qq + - poetry install + - poetry run ruff ./gitbatch + environment: + PY_COLORS: "1" diff --git a/.woodpecker/notify.yml b/.woodpecker/notify.yml new file mode 100644 index 0000000..a851904 --- /dev/null +++ b/.woodpecker/notify.yml @@ -0,0 +1,26 @@ +--- +when: + - event: [tag] + - event: [push, manual] + branch: + - ${CI_REPO_DEFAULT_BRANCH} + +runs_on: [success, failure] + +steps: + matrix: + image: quay.io/thegeeklab/wp-matrix + settings: + homeserver: + from_secret: matrix_homeserver + password: + from_secret: matrix_password + roomid: + from_secret: matrix_roomid + username: + from_secret: matrix_username + when: + - status: [success, failure] + +depends_on: + - docs diff --git a/.woodpecker/test.yml b/.woodpecker/test.yml new file mode 100644 index 0000000..1091d9f --- /dev/null +++ b/.woodpecker/test.yml @@ -0,0 +1,30 @@ +--- +when: + - event: [pull_request, tag] + - event: [push, manual] + branch: + - ${CI_REPO_DEFAULT_BRANCH} + +matrix: + PYTHON_VERSION: + - docker.io/library/python:3.7 + - docker.io/library/python:3.8 + - docker.io/library/python:3.9 + - docker.io/library/python:3.10 + - docker.io/library/python:3.11 + +steps: + fetch: + image: docker.io/library/python:3.11 + commands: + - git fetch -tq + + pytest: + image: ${PYTHON_VERSION} + commands: + - pip install poetry poetry-dynamic-versioning -qq + - poetry install + - poetry version + - poetry run git-batch --help + environment: + PY_COLORS: "1" diff --git a/Dockerfile.multiarch b/Containerfile.multiarch similarity index 100% rename from Dockerfile.multiarch rename to Containerfile.multiarch diff --git a/README.md b/README.md index 3ef24a3..7467206 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ Automate cloning a single branch from a list of repositories -[![Build Status](https://img.shields.io/drone/build/thegeeklab/git-batch?logo=drone&server=https%3A%2F%2Fdrone.thegeeklab.de)](https://drone.thegeeklab.de/thegeeklab/git-batch) +[![Build Status](https://ci.thegeeklab.de/api/badges/thegeeklab/git-batch/status.svg)](https://ci.thegeeklab.de/repos/thegeeklab/git-batch) [![Docker Hub](https://img.shields.io/badge/dockerhub-latest-blue.svg?logo=docker&logoColor=white)](https://hub.docker.com/r/thegeeklab/git-batch) [![Quay.io](https://img.shields.io/badge/quay-latest-blue.svg?logo=docker&logoColor=white)](https://quay.io/repository/thegeeklab/git-batch) [![Python Version](https://img.shields.io/pypi/pyversions/git-batch.svg)](https://pypi.org/project/git-batch/)