File tree Expand file tree Collapse file tree 3 files changed +11
-5
lines changed
Expand file tree Collapse file tree 3 files changed +11
-5
lines changed Original file line number Diff line number Diff line change 8181 "e2e:run-server" : " node dist/web/server.js" ,
8282 "e2e:install" : " npx playwright install --with-deps" ,
8383 "e2e:show-report" : " npx playwright show-report tests/report" ,
84- "update-changelog" : " ./update-changelog.sh" ,
84+ "update-changelog" : " ./scripts/changelog/ update-changelog.sh" ,
8585 "prepare" : " husky"
8686 },
8787 "author" : " O(1) Labs" ,
File renamed without changes.
Original file line number Diff line number Diff line change 1919# Ensure that you have the necessary permissions to commit and push changes to the repository.
2020
2121# Step 1: Capture the latest version
22- latest_version=$( grep -oP ' \[\K[0-9]+\.[0-9]+\.[0-9]+(?=\])' CHANGELOG.md | head -1)
22+ latest_version=$( grep -o ' \[\K[0-9]+\.[0-9]+\.[0-9]+(?=\])' CHANGELOG.md | head -1)
2323echo " Latest version: $latest_version "
2424
2525# Step 2: Bump the patch version
@@ -37,11 +37,17 @@ current_date=$(date +%Y-%m-%d)
3737echo " Current date: $current_date "
3838
3939# Step 5: Extract the second SHA from the compare URL of the latest version
40- previous_commit=$( grep -m 1 -oP ' \[.*?\]\(https://github.com/o1-labs/o1js/compare/[a-f0-9]+\.\.\.\K[a-f0-9]+(?=\))' CHANGELOG.md)
40+ previous_commit=$( grep -m 1 -o ' \[.*?\]\(https://github.com/o1-labs/o1js/compare/[a-f0-9]+\.\.\.\K[a-f0-9]+(?=\))' CHANGELOG.md)
4141echo " Previous commit: $previous_commit "
4242
4343# Step 6: Update the CHANGELOG
4444sed -i " s/\[Unreleased\](.*\.\.\.HEAD)/\[Unreleased\](https:\/\/github.com\/o1-labs\/o1js\/compare\/$current_commit ...HEAD)\n\n## \[$new_version \](https:\/\/github.com\/o1-labs\/o1js\/compare\/$previous_commit ...$current_commit ) - $current_date /" CHANGELOG.md
4545
46- # Step 7: Auto-fix compare URLs for all past versions
47- node fix-changelog-links.cjs
46+ # Step 7: Auto-fix compare URLs for all past versions, if -r is set
47+ while getopts " r" opt; do
48+ case $opt in
49+ r)
50+ node scripts/changelog/fix-changelog-links.cjs
51+ ;;
52+ esac
53+ done
You can’t perform that action at this time.
0 commit comments