Skip to content

Commit

Permalink
scanpolicies: Workflow adjustment
Browse files Browse the repository at this point in the history
Remove specification of repository (-R) when creating the PR, and
re-ordered a few things to make the flow more logical.
There's a chance it still needs a fetch for upstream, but I believe the
ambiguity error was caused by having upstream set and specifying a repo.

Signed-off-by: kingthorin <kingthorin@users.noreply.github.com>
  • Loading branch information
kingthorin committed Dec 2, 2024
1 parent ce0408a commit 3644c6a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/generate_policies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,12 @@ jobs:
export GITHUB_USER=zapbot
git config --global user.email "12745184+zapbot@users.noreply.github.com"
git config --global user.name $GITHUB_USER
export GITHUB_TOKEN=${{ secrets.ZAPBOT_TOKEN }}
BRANCH=scan-policies-updt
cd zap-extensions
git remote add upstream https://github.com/zaproxy/zap-extensions.git
SRC_BASE="zaproxy/zap-extensions@"$(git log -1 --format=format:%h)
export GITHUB_TOKEN=${{ secrets.ZAPBOT_TOKEN }}
git checkout -b $BRANCH
git remote add upstream https://github.com/zaproxy/zap-extensions.git
# Update the index to be sure git is aware of changes
git update-index -q --refresh
git add .
Expand All @@ -50,5 +50,5 @@ jobs:
git add .
git commit -m "Update scan policies based on Tags" -m "Updates based on $SRC_BASE" --signoff
git push --set-upstream origin $BRANCH --force
gh pr create -R zaproxy/zap-extensions --fill
gh pr create --fill
fi

0 comments on commit 3644c6a

Please sign in to comment.