diff --git a/CMakeLists.txt b/CMakeLists.txt index 9daf4ea55..fa0b7207b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,6 +1,6 @@ # SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-or-later # SPDX-FileCopyrightText: Bradley M. Bell -# SPDX-FileContributor: 2003-23 Bradley M. Bell +# SPDX-FileContributor: 2003-24 Bradley M. Bell # ---------------------------------------------------------------------------- # ============================================================================= # Some constants @@ -16,7 +16,7 @@ IF( POLICY CMP0054 ) ENDIF( POLICY CMP0054 ) # # cppad_version is used by version.sh to get the version number. -SET(cppad_version "20240223") +SET(cppad_version "20240224") SET(cppad_url "https://coin-or.github.io/CppAD" ) SET(cppad_description "Differentiation of C++ Algorithms" ) IF( NOT DEFINED CMAKE_BUILD_TYPE) diff --git a/bin/check_copy.sh b/bin/check_copy.sh index 5b3c959eb..2a5f28bf2 100755 --- a/bin/check_copy.sh +++ b/bin/check_copy.sh @@ -57,7 +57,8 @@ do if [ -e $file_name ] then sed \ - -e 's|\(SPDX-FileContributor\): \([0-9]\{4\}\)[-0-9]* |\1: \2-24 |' \ + -e 's|\(SPDX-FileContributor\): *\([0-9]\{4\}\)[-0-9]* |\1: \2-24 |' \ + -e 's|\(SPDX-FileContributor\): 2024-24 |\1: 2024 |' \ $file_name > temp.$$ if diff $file_name temp.$$ > /dev/null then diff --git a/bin/check_version.sh b/bin/check_version.sh index 7c87a8a2d..92bd10457 100755 --- a/bin/check_version.sh +++ b/bin/check_version.sh @@ -2,7 +2,7 @@ set -e -u # SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-or-later # SPDX-FileCopyrightText: Bradley M. Bell -# SPDX-FileContributor: 2003-22 Bradley M. Bell +# SPDX-FileContributor: 2003-24 Bradley M. Bell # ---------------------------------------------------------------------------- if [ $# != 0 ] then @@ -46,31 +46,21 @@ version=$( sed -e 's|.*"\([^"]*\)".*|\1|' ) # -# version, release -release='yes' -if echo $version | grep '[0-9]\{4\}0000[.]' > /dev/null +# branch +branch=$(git branch | sed -n -e '/^[*]/p' | sed -e 's|^[*] *||') +# +# version +if [ "$branch" == 'master' ] +then + version=$( date +%Y%m%d ) +fi +if echo $branch | grep '^stable/' > /dev/null then - res='' - while [ "$res" != 'ok' ] && [ "$res" != 'date' ] && [ "$res" != 'abort' ] - do - echo "In CMakeLists.txt version = $version" - echo 'ok: use this version.' - echo 'date: repalce this by the current date.' - echo 'abort: if you whish to change the version in CMakeLists.txt.' - read -p '[ok/date/abort] ?' res - done - if [ "$res" == 'abort' ] + if ! echo $version | grep '^[0-9]\{4\}0000[.]' > /dev/null then + echo 'check_version.sh: Stable version does not begin with yyyy0000.' exit 1 fi - if [ "$res" == 'date' ] - then - release='no' - version=$( date +%Y%m%d ) - fi -else - release='no' - version=$( date +%Y%m%d ) fi # # version_ok @@ -83,7 +73,7 @@ version_files=' ' # # temp.sed -if [ "$release" == 'yes' ] +if echo $branch | grep '^stable/' > /dev/null then stable=$( echo $version | sed -e 's|[.][0-9]*$||' ) cat << EOF > temp.sed diff --git a/user_guide.xrst b/user_guide.xrst index 635e7e81c..129731881 100644 --- a/user_guide.xrst +++ b/user_guide.xrst @@ -1,6 +1,6 @@ # SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-or-later # SPDX-FileCopyrightText: Bradley M. Bell -# SPDX-FileContributor: 2003-23 Bradley M. Bell +# SPDX-FileContributor: 2003-24 Bradley M. Bell # ---------------------------------------------------------------------------- {xrst_begin user_guide} {xrst_spell @@ -13,7 +13,7 @@ {xrst_comment BEGIN: Before changing see new_release.sh and check_version.sh} -cppad-20240223: CppAD User's Manual +cppad-20240224: CppAD User's Manual ################################### .. image:: {xrst_dir coin.png}