Skip to content
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 2 additions & 14 deletions .github/workflows/mirror_noir_subrepo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,25 +21,12 @@ jobs:
runs-on: ubuntu-latest

steps:
- name: Get noir master's last sync commit
id: last_merge_hash
uses: actions/github-script@v7
with:
script: |
// NOTE: more robust heuristic needed if aztecbot opens different kinds of PRs
const response = await github.rest.search.commits({
q: 'author:AztecBot committer:web-flow repo:noir-lang/noir sort:committer-date'
});
console.log(response.data.items);
return response.data.items[0].sha;

- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
token: ${{ secrets.AZTEC_BOT_GITHUB_TOKEN }}


- name: Setup env
run: |
set -xue # print commands
Expand All @@ -55,7 +42,8 @@ jobs:
LAST_MERGED_PR_HASH=`gh pr list --repo=noir-lang/noir --state merged --head aztec-packages --json headRefOid --jq=.[0].headRefOid`
# Use a commit heuristic where we look at when .gitrepo first started to look at that commit state (through a push)
COMMIT_HEURISTIC=$(git log -p -S"$LAST_MERGED_PR_HASH" --reverse --source -- noir/.gitrepo | grep -m 1 '^commit' | awk '{print $2}' || true)
if [[ " $COMMIT_HEURISTIC" = "" ]] ; then
BASE_AZTEC_COMMIT=`git config --file=noir/.gitrepo subrepo.parent`
if [[ "$COMMIT_HEURISTIC" = "" ]] ; then
# It it fails, just use our gitrepo parent commit (last time we pushed or pulled)
COMMIT_HEURISTIC=$BASE_AZTEC_COMMIT
fi
Expand Down
6 changes: 3 additions & 3 deletions noir/.gitrepo
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
;
[subrepo]
remote = https://github.com/noir-lang/noir
branch = aztec-packages
commit = 6ff518af281afe601edb8574d425b07d9d2f9c5d
parent = 2082fedfb03d4882a269881f51c5337263bc539b
branch = aztec-test-sync
commit = be6ae018e484621f7a0743df5951f8ef0a45af98
parent = ac87124e8fbb756cc34180a174011e33bfe19217
method = merge
cmdver = 0.4.6