Skip to content

Commit

Permalink
Merge pull request #686 from arunsathiya/master
Browse files Browse the repository at this point in the history
ci: Use GITHUB_OUTPUT envvar instead of set-output command
  • Loading branch information
vvuksan authored Feb 13, 2024
2 parents 1238194 + 21a7132 commit f48a796
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/shielding-check-cron-manual.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ jobs:
run: |
cat ./temp.json | jq . > etc/shielding/datacenters.json
rm -f ./temp.json
echo "::set-output name=diff-count::$(git diff --name-only | wc -l)"
echo "diff-count=$(git diff --name-only | wc -l)" >> "$GITHUB_OUTPUT"
SHA1=`sha1sum etc/shielding/datacenters.json | awk '{print $1}'`
echo "::set-output name=sha1::$SHA1"
echo "::set-output name=pr-count::$(gh pr list --search "${SHA1} in:title is:open" --json title -q '.[] | .title' | wc -l)"
echo "sha1=$SHA1" >> "$GITHUB_OUTPUT"
echo "pr-count=$(gh pr list --search "${SHA1} in:title is:open" --json title -q '.[] | .title' | wc -l)" >> "$GITHUB_OUTPUT"
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Check diff and create PR
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/shielding-check-cron.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ jobs:
run: |
cat ./temp.json | jq . > etc/shielding/datacenters.json
rm -f ./temp.json
echo "::set-output name=diff-count::$(git diff --name-only | wc -l)"
echo "diff-count=$(git diff --name-only | wc -l)" >> "$GITHUB_OUTPUT"
SHA1=`sha1sum etc/shielding/datacenters.json | awk '{print $1}'`
echo "::set-output name=sha1::$SHA1"
echo "::set-output name=pr-count::$(gh pr list --search "${SHA1} in:title is:open" --json title -q '.[] | .title' | wc -l)"
echo "sha1=$SHA1" >> "$GITHUB_OUTPUT"
echo "pr-count=$(gh pr list --search "${SHA1} in:title is:open" --json title -q '.[] | .title' | wc -l)" >> "$GITHUB_OUTPUT"
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Check diff and create PR
Expand Down

0 comments on commit f48a796

Please sign in to comment.