From 8a5a151a4db1caeac4a1ce6c1ce0b045a9ea1ed7 Mon Sep 17 00:00:00 2001 From: Jirka Date: Wed, 14 Jul 2021 15:01:41 +0200 Subject: [PATCH] add DeepSource & Mergify --- .deepsource.toml | 25 +++++++++++++++++++++++++ .github/mergify.yml | 33 +++++++++++++++++++++++++++++++++ MANIFEST.in | 1 + 3 files changed, 59 insertions(+) create mode 100644 .deepsource.toml create mode 100644 .github/mergify.yml diff --git a/.deepsource.toml b/.deepsource.toml new file mode 100644 index 0000000..e8fb6d4 --- /dev/null +++ b/.deepsource.toml @@ -0,0 +1,25 @@ +version = 1 + +exclude_patterns = [ + ".github/**", +] + +test_patterns = [ + "tests/**", + "test_*.py" +] + +[[analyzers]] +name = "test-coverage" +enabled = true + +[[analyzers]] +name = "docker" +enabled = true + +[[analyzers]] +name = "python" +enabled = true + + [analyzers.meta] + runtime_version = "3.x.x" diff --git a/.github/mergify.yml b/.github/mergify.yml new file mode 100644 index 0000000..09745e9 --- /dev/null +++ b/.github/mergify.yml @@ -0,0 +1,33 @@ +pull_request_rules: + + - name: warn on conflicts + conditions: + - conflict + - -draft # filter-out GH draft PRs + - -label="has conflicts" + actions: + # comment: + # message: This pull request is now in conflict... :( + label: + add: [ "has conflicts" ] + + - name: resolved conflicts + conditions: + - -conflict + - label="has conflicts" + - -draft # filter-out GH draft PRs + - -merged # not merged yet + - -closed + actions: + label: + remove: [ "has conflicts" ] + + - name: update PR + conditions: + - -conflict + - -draft # filter-out GH draft PRs + - base=master # apply only on master + - -title~=(?i)wip # skip all PR that title contains “WIP” (ignoring case) + - "#approved-reviews-by>=1" # number of review approvals + actions: + update: {} diff --git a/MANIFEST.in b/MANIFEST.in index 92eab23..8492de1 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -46,6 +46,7 @@ include *.txt # Exclude build configs exclude *.yml *.yaml +exclude *.toml prune .git prune .github