diff options
| author | TiejunZhou <[email protected]> | 2023-10-23 15:31:03 +0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2023-10-23 15:31:03 +0800 |
| commit | 13b700fd3ed763cedcba7dbd17b859077a01aa9c (patch) | |
| tree | dce98f5940c79679029fc79109b8c6af166bbfaf /scripts/update_patch.sh | |
| parent | 9ee2738aec92ecab0dd321dd5836f56927f72b7a (diff) | |
Update release version to 6.3.0 and date to 10-31-2023 (#308)v6.3.0_rel
Diffstat (limited to 'scripts/update_patch.sh')
| -rwxr-xr-x | scripts/update_patch.sh | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/scripts/update_patch.sh b/scripts/update_patch.sh new file mode 100755 index 00000000..92e1ba90 --- /dev/null +++ b/scripts/update_patch.sh @@ -0,0 +1,20 @@ +#!/bin/bash + +if [ "$#" -ne 2 ]; then + echo "Usage: $0 \"<version>\" \"<date>\"" + exit 1 +fi + +cd $(dirname `realpath $0`)/.. +current_version="6\\.x" +source_dirs="common common_modules common_smp ports ports_module ports_smp ports_arch utility" +file_list=$(find $source_dirs -type f \( -name "*.[chsS]" -o -name "*.arm" -o -name "*.src" -o -name "*readme*" -o -name "*.mip" \) -print) + +sed -i "s/$current_version /$1/g" $file_list +sed -i "s/$current_version/$1/g" $file_list +sed -i "s/xx-xx-xxxx/$2/g" $file_list + +# Update version in port files +source_dirs="ports ports_module ports_smp ports_arch" +file_list=$(find $source_dirs -type f -name "*.h" -print) +sed -i "/\"Copyright/,/[0-9]\.[0-9]/s/[0-9]\.[0-9\.]\+/$1/" $file_list |
