From 5022eae03fe83a7fb94891b952a72d83276329ff Mon Sep 17 00:00:00 2001 From: zeme-wana <15709674+zeme-wana@users.noreply.github.com> Date: Tue, 11 Feb 2025 16:01:54 +0100 Subject: [PATCH] Fix version replacement snippet in scripts/interactive-release.sh (#6836) --- scripts/interactive-release.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/scripts/interactive-release.sh b/scripts/interactive-release.sh index 12b88fafb25..953a42ac6f5 100755 --- a/scripts/interactive-release.sh +++ b/scripts/interactive-release.sh @@ -138,18 +138,18 @@ open-plutus-pr() { for PACKAGE in "${RELEASE_PACKAGES[@]}"; do find . -name "?*.cabal" \ -exec sed -i "s/\(^version:\s*\).*/\1$VERSION/" "./$PACKAGE/$PACKAGE.cabal" \; \ - -exec sed -i "s/\(^[ \t]*,[ \t]*$PACKAGE[^-A-Za-z0-1][^^]*\).*/\1^>=$MAJOR_VERSION/" {} \; \ - -exec sed -i "s/\(^[ \t]*,[ \t]*$PACKAGE$\)/\1 ^>=$MAJOR_VERSION/" {} \; + -exec sed -i "s/\([^,:]*.[ \t]*$PACKAGE[^-A-Za-z0-1][^^]*\).*/\1^>=$MAJOR_VERSION/" {} \; \ + -exec sed -i "s/\([^,:]*.[ \t]*$PACKAGE$\)/\1 ^>=$MAJOR_VERSION/" {} \; pushd $PACKAGE > /dev/null scriv collect --version $VERSION || true popd > /dev/null done - git add . + git add . pre-commit run cabal-fmt || true # pre-commit will fail but will modify the files in place, hence the second git add . below - git add . - git commit -m "Release $VERSION" || true + git add . + git commit -m "Release $VERSION" || true git push --force --set-upstream origin $PR_BRANCH local PR_URL=$(gh pr create \