-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'origin/master' into perf-nim
- Loading branch information
Showing
39 changed files
with
2,390 additions
and
2,278 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
name: Add new implementation versions | ||
|
||
on: | ||
workflow_dispatch: | ||
schedule: | ||
# “At minute 36 past every 24th hour.” - https://crontab.guru/#36_*/24_*_*_* | ||
- cron: '36 */24 * * *' | ||
|
||
defaults: | ||
run: | ||
shell: bash | ||
|
||
permissions: | ||
contents: write | ||
pull-requests: write | ||
actions: write | ||
|
||
jobs: | ||
go: | ||
runs-on: ubuntu-latest | ||
env: | ||
DIR: perf/impl/go-libp2p | ||
REPO: libp2p/go-libp2p | ||
BRANCH: perf/go-libp2p | ||
steps: | ||
- name: Checkout test-plans | ||
uses: actions/checkout@v3 | ||
- name: Configure git | ||
run: | | ||
git fetch origin $BRANCH && git checkout $BRANCH || git checkout -b $BRANCH | ||
git rebase $GITHUB_REF -X theirs || git rebase --abort | ||
git config --global user.email $GITHUB_ACTOR@users.noreply.github.com | ||
git config --global user.name $GITHUB_ACTOR | ||
- id: go | ||
uses: actions/setup-go@v3 | ||
with: | ||
go-version: stable | ||
- name: Get the latest version (local) | ||
id: local | ||
run: ls -d v* | sort -V | tail -n-1 | xargs -I{} echo "version={}" | tee -a $GITHUB_OUTPUT | ||
working-directory: ${{ env.DIR }} | ||
- name: Get the latest version (remote) | ||
id: remote | ||
env: | ||
GITHUB_TOKEN: ${{ github.token }} | ||
run: gh api repos/$REPO/releases/latest --jq '.tag_name' | xargs -I{} echo "version={}" | tee -a $GITHUB_OUTPUT | ||
- name: Add the latest version | ||
if: ${{ !startsWith(steps.remote.outputs.version, steps.local.outputs.version) }} | ||
env: | ||
LOCAL_VERSION: ${{ steps.local.outputs.version }} | ||
REMOTE_VERSION: ${{ steps.remote.outputs.version }} | ||
GO_VERSION: ${{ steps.go.outputs.go-version }} | ||
GITHUB_TOKEN: ${{ github.token }} | ||
run: | | ||
majorMinorRemoteVersion=$(echo $REMOTE_VERSION | sed 's/\.[0-9]*$//') | ||
majorMinorGoVersion=$(echo $GO_VERSION | sed 's/\.[0-9]*$//') | ||
cp -r $LOCAL_VERSION $majorMinorRemoteVersion | ||
cd $majorMinorRemoteVersion | ||
sed -i "1s/$LOCAL_VERSION/$majorMinorRemoteVersion/g" go.mod | ||
go mod tidy -go=$majorMinorGoVersion | ||
go mod tidy | ||
go get github.com/libp2p/go-libp2p@$REMOTE_VERSION | ||
git add . | ||
git commit -m "chore: add go-libp2p@$REMOTE_VERSION to $DIR" | ||
git push origin $BRANCH --force | ||
# create a PR if an open one doesn't exist yet | ||
if [[ $(gh pr list --state open --base $GITHUB_REF --head $BRANCH | wc -l) -eq 0 ]]; then | ||
gh pr create --title "chore: add go-libp2p@$REMOTE_VERSION to $DIR" --body "This PR adds go-libp2p@$REMOTE_VERSION to $DIR" --head $BRANCH --base $GITHUB_REF | ||
fi | ||
gh workflow run perf.yml --ref $BRANCH | ||
working-directory: ${{ env.DIR }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
4 changes: 2 additions & 2 deletions
4
multidim-interop/impl/go/v0.28/Makefile → multidim-interop/impl/go/v0.30/Makefile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
image_name := go-v0.28 | ||
version := 0.28.3 | ||
image_name := go-v0.30 | ||
version := 0.30.0 | ||
|
||
all: image.json | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ce648ef713f6c68f9edf88e725605702ceb665ddc4c8a1b528f738a8689db1f3 go-libp2p-0.30.0.zip |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
fab332959e47bc8c7c5ed870f1f138d782c169f75ecf35eb274b46fefa83e29b go-libp2p-0.31.0.zip |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.