Patchwork D9727: ci: report status to phabricator on failures

login
register
mail settings
Submitter phabricator
Date Jan. 12, 2021, 12:08 p.m.
Message ID <differential-rev-PHID-DREV-46ahoi5o3snimvx5sf4w-req@mercurial-scm.org>
Download mbox | patch
Permalink /patch/48038/
State New
Headers show

Comments

phabricator - Jan. 12, 2021, 12:08 p.m.
danchr created this revision.
Herald added a reviewer: hg-reviewers.
Herald added a subscriber: mercurial-patches.

REPOSITORY
  rHG Mercurial

BRANCH
  default

REVISION DETAIL
  https://phab.mercurial-scm.org/D9727

AFFECTED FILES
  contrib/heptapod-ci.yml

CHANGE DETAILS




To: danchr, #hg-reviewers
Cc: mercurial-patches, mercurial-devel

Patch

diff --git a/contrib/heptapod-ci.yml b/contrib/heptapod-ci.yml
--- a/contrib/heptapod-ci.yml
+++ b/contrib/heptapod-ci.yml
@@ -1,7 +1,6 @@ 
 stages:
   - tests
   - packages
-  - phabricator
 
 image: registry.heptapod.net/mercurial/ci-images/mercurial-core
 
@@ -52,10 +51,27 @@ 
             - PYTHON: [python2, python3]
             - {PYTHON: [python3], HG_RUST_FEATURES: [dirstate-tree]}
 
-phabricator-refresh:
-    stage: phabricator
+phabricator-success:
+    stage: .post
+    when: on_success
     script:
-      - "./contrib/phab-refresh-stack.sh --comment \":white_check_mark: refresh by Heptapod after a successful CI run (:octopus: :green_heart:)\""
+      - >
+          ./contrib/phab-refresh-stack.sh
+          --comment ":white_check_mark: refresh by
+          Heptapod after a successful CI run (:octopus: :green_heart:)
+          \n\n
+          ${CI_PIPELINE_URL}"
+
+phabricator-failure:
+    stage: .post
+    when: on_failure
+    script:
+      - >
+          ./contrib/phab-refresh-stack.sh
+          --comment ":negative_squared_cross_mark: refresh by
+          Heptapod after a failed CI run (:octopus: :heart:)
+          \n\n
+          ${CI_PIPELINE_URL}"
 
 test:
     extends: .runtests_template