Skip to content

Commit

Permalink
Remove hard-coding of RAPIDS version (#711)
Browse files Browse the repository at this point in the history
* Read `cucim.__version__` in docs build
* Remove update from `ci/release/update-version.sh`

Issue: rapidsai/build-planning#15

Authors:
  - Kyle Edwards (https://github.com/KyleFromNVIDIA)

Approvers:
  - Bradley Dice (https://github.com/bdice)
  - Jake Awe (https://github.com/AyodeAwe)

URL: #711
  • Loading branch information
KyleFromNVIDIA authored Mar 8, 2024
1 parent 5ffe82b commit a661e09
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 0 additions & 4 deletions ci/release/update-version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,6 @@ function sed_runner() {
sed -i.bak ''"$1"'' $2 && rm -f ${2}.bak
}

# RTD update
sed_runner 's/version = .*/version = "'"${NEXT_SHORT_TAG}"'"/g' docs/source/conf.py
sed_runner 's/release = .*/release = "'"${NEXT_FULL_TAG}"'"/g' docs/source/conf.py

# Centralized version file update
echo "${NEXT_FULL_TAG}" > VERSION

Expand Down
8 changes: 6 additions & 2 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@
#
import os
import sys
from packaging.version import Version

import cucim

sys.path.insert(0, os.path.abspath("../.."))
curpath = os.path.dirname(__file__)
Expand Down Expand Up @@ -71,10 +74,11 @@
# |version| and |release|, also used in various other places throughout the
# built documents.
#
CUCIM_VERSION = Version(cucim.__version__)
# The short X.Y version.
version = "24.04"
version = f"{CUCIM_VERSION.major:02}.{CUCIM_VERSION.minor:02}"
# The full version, including alpha/beta/rc tags.
release = "24.04.00"
release = f"{CUCIM_VERSION.major:02}.{CUCIM_VERSION.minor:02}.{CUCIM_VERSION.micro:02}"

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down

0 comments on commit a661e09

Please sign in to comment.