diff --git a/.woodpecker/push.yml b/.woodpecker.yml similarity index 60% rename from .woodpecker/push.yml rename to .woodpecker.yml index e33888c..af55983 100644 --- a/.woodpecker/push.yml +++ b/.woodpecker.yml @@ -9,10 +9,18 @@ pipeline: image: registry.gitlab.com/dmoonfire/nix-flake-docker:latest commands: - nix develop --command scripts/build.sh + when: + event: [push, pull_request, tag] + tag: v* + + test: + image: registry.gitlab.com/dmoonfire/nix-flake-docker:latest + commands: - nix develop --command scripts/test.sh when: event: [push, pull_request] - release: + + release-main: image: registry.gitlab.com/dmoonfire/nix-flake-docker:latest commands: - export DRONE="true" # Required to convince `env-ci` that it is a known CI @@ -22,5 +30,18 @@ pipeline: - gitea_token - git_credentials when: - event: [push] + event: push branch: main + + release-gitea: + image: plugins/gitea-release + settings: + base_url: https://src.mfgames.com + files: + - "*.pdf" + - "*.epub" + api_key: + from_secret: gitea_token + when: + event: tag + tag: v* diff --git a/.woodpecker/tag.yml b/.woodpecker/tag.yml deleted file mode 100644 index 083b55a..0000000 --- a/.woodpecker/tag.yml +++ /dev/null @@ -1,25 +0,0 @@ -clone: - git: - image: woodpeckerci/plugin-git - settings: - tags: true - -pipeline: - build: - image: registry.gitlab.com/dmoonfire/nix-flake-docker:latest - commands: - - nix develop --command scripts/build.sh - when: - event: [tag] - tag: v* - gitea: - image: plugins/gitea-release - settings: - base_url: https://src.mfgames.com - files: exit-planning*.* - secrets: - - source: gitea_token - target: plugin_api_key - when: - event: [tag] - tag: v*