Skip to content

Commit

Permalink
GEOS-Chem Classic 14.2.3 release
Browse files Browse the repository at this point in the history
This is the official release of GEOS-Chem Classic 14.2.3.  Updates include:

- GEOS-Chem (science codebase) 14.2.3
- HEMCO 3.7.2
- Add utility script to change version numbers before release (PR #46)

Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
  • Loading branch information
yantosca committed Dec 1, 2023
2 parents f5b5694 + 35c7394 commit cfb0626
Show file tree
Hide file tree
Showing 6 changed files with 127 additions and 4 deletions.
119 changes: 119 additions & 0 deletions .release/changeVersionNumbers.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,119 @@
#!/bin/bash

#EOC
#------------------------------------------------------------------------------
# GEOS-Chem Global Chemical Transport Model !
#------------------------------------------------------------------------------
#BOP
#
# !MODULE: changeVersionNumbers.sh
#
# !DESCRIPTION: Bash script to change the version numbers in the appropriate
# files in the GCClassic directory structure. Run this before releasing
# a new GEOS-Chem Classic version.
#\\
#\\
# !CALLING SEQUENCE:
# $ ./changeVersionNumbers.sh X.Y.Z # X.Y.Z = GCClassic version number
#EOP
#------------------------------------------------------------------------------
#BOC

function replace() {

#========================================================================
# Function to replace text in a file via sed.
#
# 1st argument: Search pattern
# 2nd argument: Replacement text
# 3rd argument: File in which to search and replace
#========================================================================

sed -i -e "s/${1}/${2}/" "${3}"
}


function exitWithError() {

#========================================================================
# Display and error message and exit
#========================================================================

echo "Could not update version numbers in ${1}... Exiting!"
exit 1
}


function main() {

#========================================================================
# Replaces the version number in the files listed.
#
# 1st argument: New version number to use
#========================================================================

# New version number
version="${1}"

# Save this directory path and change to root directory
thisDir=$(pwd -P)
cd ..

#========================================================================
# Update version numbers in various files
#========================================================================

# Pattern to match: X.Y.Z
pattern='[0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*'

# List of files to replace
files=( \
"CMakeLists.txt" \
"docs/source/conf.py" \
)

# Replace version numbers in files
for file in ${files[@]}; do
replace "${pattern}" "${version}" "${file}"
[[ $? -ne 0 ]] && exitWithError "${file}"
echo "GCClassic version updated to ${version} in ${file}"
done

#========================================================================
# Update version number and date in CHANGELOG.md
#========================================================================

# Pattern to match: "[Unreleased] - TBD"
pattern='\[.*Unreleased.*\].*'
date=$(date -Idate)

# List of files to replace
files=( \
"CHANGELOG.md" \
"src/GEOS-Chem/CHANGELOG.md" \
)

# Replace version numbers in files
for file in ${files[@]}; do
replace "${pattern}" "\[${version}\] - ${date}" "${file}"
[[ $? -ne 0 ]] && exitWithError "${file}"
echo "GCClassic version updated to ${version} in ${file}"
done

# Return to the starting directory
cd "${thisDir}"
}

# ---------------------------------------------------------------------------

# Expect 1 argument, or exit with error
if [[ $# -ne 1 ]]; then
echo "Usage: ./changeVersionNumbers.sh VERSION"
exit 1
fi

# Replace version numbers
main "${1}"

# Return status
exit $?
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ This file documents all notable changes to the GEOS-Chem Classic wrapper reposit

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [14.2.3] - 2023-12-01
### Added
- Script `.release/changeVersionNumbers.sh` to change version numbers before a new GEOS-Chem Classic release

## [14.2.2] - 2023-10-23
### Changed
- Updated GEOS-Chem submodule to 14.2.2
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

cmake_minimum_required (VERSION 3.13)
project (geos-chem-classic
VERSION 14.2.2
VERSION 14.2.3
LANGUAGES Fortran
)

Expand Down
2 changes: 1 addition & 1 deletion docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
author = 'GEOS-Chem Support Team'

# The full version, including alpha/beta/rc tags
release = '14.2.2'
release = '14.2.3'


# -- General configuration ---------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion src/GEOS-Chem
Submodule GEOS-Chem updated 65 files
+31 −2 CHANGELOG.md
+5 −4 GeosCore/aero_drydep.F90
+27 −13 GeosCore/aerosol_mod.F90
+20 −6 GeosCore/airs_ch4_mod.F90
+5 −3 GeosCore/calc_met_mod.F90
+24 −9 GeosCore/carbon_mod.F90
+22 −20 GeosCore/chemistry_mod.F90
+11 −6 GeosCore/diagnostics_mod.F90
+3 −2 GeosCore/dust_mod.F90
+106 −15 GeosCore/fullchem_mod.F90
+20 −7 GeosCore/gosat_ch4_mod.F90
+18 −8 GeosCore/hco_interface_gc_mod.F90
+19 −7 GeosCore/hco_utilities_gc_mod.F90
+1 −1 GeosCore/input_mod.F90
+20 −9 GeosCore/linear_chem_mod.F90
+47 −25 GeosCore/mercury_mod.F90
+26 −8 GeosCore/mixing_mod.F90
+22 −12 GeosCore/pbl_mix_mod.F90
+19 −7 GeosCore/rrtmg_rad_transfer_mod.F90
+19 −11 GeosCore/set_boundary_conditions_mod.F90
+22 −10 GeosCore/set_global_ch4_mod.F90
+70 −25 GeosCore/sulfate_mod.F90
+70 −49 GeosCore/tomas_mod.F90
+19 −8 GeosCore/tracer_mod.F90
+3 −3 GeosCore/ucx_mod.F90
+19 −9 GeosCore/vdiff_mod.F90
+31 −17 GeosCore/wetscav_mod.F90
+425 −367 GeosUtil/unitconv_mod.F90
+11 −5 Headers/input_opt_mod.F90
+2 −2 Headers/state_chm_mod.F90
+8 −11 Headers/state_diag_mod.F90
+3 −3 History/history_mod.F90
+34 −23 Interfaces/GCHP/gchp_chunk_mod.F90
+35 −14 Interfaces/GEOS/geos_CarbonInterface.F90
+23 −11 ObsPack/obspack_mod.F90
+10 −7 run/GCClassic/HEMCO_Config.rc.templates/HEMCO_Config.rc.CH4
+0 −1 run/GCClassic/HEMCO_Config.rc.templates/HEMCO_Config.rc.CO2
+0 −1 run/GCClassic/HEMCO_Config.rc.templates/HEMCO_Config.rc.Hg
+0 −1 run/GCClassic/HEMCO_Config.rc.templates/HEMCO_Config.rc.POPs
+0 −1 run/GCClassic/HEMCO_Config.rc.templates/HEMCO_Config.rc.TransportTracers
+8 −5 run/GCClassic/HEMCO_Config.rc.templates/HEMCO_Config.rc.aerosol
+19 −11 run/GCClassic/HEMCO_Config.rc.templates/HEMCO_Config.rc.carbon
+9 −5 run/GCClassic/HEMCO_Config.rc.templates/HEMCO_Config.rc.fullchem
+0 −1 run/GCClassic/HEMCO_Config.rc.templates/HEMCO_Config.rc.metals
+272 −104 run/GCClassic/HEMCO_Config.rc.templates/HEMCO_Config.rc.tagCH4
+4 −3 run/GCClassic/HEMCO_Config.rc.templates/HEMCO_Config.rc.tagCO
+0 −1 run/GCClassic/HEMCO_Config.rc.templates/HEMCO_Config.rc.tagO3
+37 −128 run/GCClassic/createRunDir.sh
+565 −0 run/GCClassic/setupForRestarts.sh
+0 −96 run/GCHP/HEMCO_Config.rc.templates/HEMCO_Config.rc.CO2
+0 −1 run/GCHP/HEMCO_Config.rc.templates/HEMCO_Config.rc.TransportTracers
+19 −11 run/GCHP/HEMCO_Config.rc.templates/HEMCO_Config.rc.carbon
+9 −5 run/GCHP/HEMCO_Config.rc.templates/HEMCO_Config.rc.fullchem
+0 −1 run/GCHP/HEMCO_Config.rc.templates/HEMCO_Config.rc.tagO3
+1 −1 run/GCHP/setCommonRunSettings.sh.template
+345 −223 run/shared/download_data.py
+36 −14 run/shared/download_data.yml
+7 −0 test/integration/GCClassic/README.md
+38 −14 test/integration/GCClassic/integrationTest.sh
+0 −5 test/integration/GCClassic/integrationTestExecute.sh
+6 −0 test/integration/GCHP/README.md
+47 −27 test/integration/GCHP/integrationTest.sh
+1 −1 test/integration/GCHP/integrationTestCompile.sh
+1 −1 test/integration/GCHP/integrationTestExecute.sh
+240 −102 test/shared/commonFunctionsForTests.sh

0 comments on commit cfb0626

Please sign in to comment.