]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
github-ci: dump github context and pr body 8489/head
authorJason Ish <jason.ish@oisf.net>
Wed, 25 Jan 2023 21:41:50 +0000 (15:41 -0600)
committerJason Ish <jason.ish@oisf.net>
Sun, 29 Jan 2023 21:38:20 +0000 (15:38 -0600)
For debugging the parsing of suricata-verify-pr.

.github/workflows/builds.yml

index 0010ff5b69b3776aa7da4067ce7e6f58c0bd3b86..9c54e07868ec73eabe60ffeced622c262ef12932 100644 (file)
@@ -38,6 +38,8 @@ jobs:
     name: Prepare dependencies
     runs-on: ubuntu-latest
     steps:
+      - name: Dumping github context for debugging
+        run: echo '${{ toJSON(github) }}'
       - run: sudo apt update && sudo apt -y install jq curl
       - name: Parse repo and branch information
         env:
@@ -49,6 +51,9 @@ jobs:
           if test "${PR_HREF}"; then
               body=$(curl -s "${PR_HREF}" | jq -r .body | tr -d '\r')
 
+              echo "Parsing branch and PR info from:"
+              echo "${body}"
+
               libhtp_repo=$(echo "${body}" | awk '/^libhtp-repo/ { print $2 }')
               libhtp_branch=$(echo "${body}" | awk '/^libhtp-branch/ { print $2 }')
               libhtp_pr=$(echo "${body}" | awk '/^libhtp-pr/ { print $2 }')
@@ -60,6 +65,8 @@ jobs:
               sv_repo=$(echo "${body}" | awk '/^suricata-verify-repo/ { print $2 }')
               sv_branch=$(echo "${body}" | awk '/^suricata-verify-branch/ { print $2 }')
               sv_pr=$(echo "${body}" | awk '/^suricata-verify-pr/ { print $2 }')
+          else
+              echo "PR_HREF is empty"
           fi
           echo "libhtp_repo=${libhtp_repo:-${DEFAULT_LIBHTP_REPO}}" >> $GITHUB_ENV
           echo "libhtp_branch=${libhtp_branch:-${DEFAULT_LIBHTP_BRANCH}}" >> $GITHUB_ENV