Fixes for problems encountered with version determination (#3320)

This commit is contained in:
Paul Romano 2025-02-24 21:49:47 -06:00 committed by GitHub
parent fed4b28616
commit 1729b3bf91
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 14 additions and 10 deletions

View file

@ -4,7 +4,9 @@ build:
os: "ubuntu-24.04"
tools:
python: "3.12"
jobs:
post_checkout:
- git fetch --unshallow || true
sphinx:
configuration: docs/source/conf.py

View file

@ -194,7 +194,7 @@ ENV LIBMESH_INSTALL_DIR=$HOME/LIBMESH
# clone and install openmc
RUN mkdir -p ${HOME}/OpenMC && cd ${HOME}/OpenMC \
&& git clone --shallow-submodules --recurse-submodules --single-branch -b ${openmc_branch} --depth=1 ${OPENMC_REPO} \
&& git clone --shallow-submodules --recurse-submodules --single-branch -b ${openmc_branch} ${OPENMC_REPO} \
&& mkdir build && cd build ; \
if [ ${build_dagmc} = "on" ] && [ ${build_libmesh} = "on" ]; then \
cmake ../openmc \

View file

@ -1,4 +1,4 @@
Copyright (c) 2011-2024 Massachusetts Institute of Technology, UChicago Argonne
Copyright (c) 2011-2025 Massachusetts Institute of Technology, UChicago Argonne
LLC, and OpenMC contributors
Permission is hereby granted, free of charge, to any person obtaining a copy of

View file

@ -39,6 +39,11 @@ if(EXISTS "${CMAKE_SOURCE_DIR}/.git" AND GIT_FOUND)
OUTPUT_STRIP_TRAILING_WHITESPACE
)
# If no tags are found, instruct user to fetch them
if(VERSION_STRING STREQUAL "")
message(FATAL_ERROR "No git tags found. Run 'git fetch --tags' and try again.")
endif()
# Extract the commit hash
execute_process(
COMMAND git rev-parse HEAD

View file

@ -62,7 +62,7 @@ master_doc = 'index'
# General information about the project.
project = 'OpenMC'
copyright = '2011-2024, Massachusetts Institute of Technology, UChicago Argonne LLC, and OpenMC contributors'
copyright = '2011-2025, Massachusetts Institute of Technology, UChicago Argonne LLC, and OpenMC contributors'
# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
@ -71,11 +71,8 @@ copyright = '2011-2024, Massachusetts Institute of Technology, UChicago Argonne
import openmc
# The short X.Y version.
version = ".".join(openmc.__version__.split('.')[:2])
# The full version, including alpha/beta/rc tags.
release = openmc.__version__
version = release = openmc.__version__
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.

View file

@ -4,7 +4,7 @@
License Agreement
=================
Copyright © 2011-2024 Massachusetts Institute of Technology, UChicago Argonne
Copyright © 2011-2025 Massachusetts Institute of Technology, UChicago Argonne
LLC, and OpenMC contributors
Permission is hereby granted, free of charge, to any person obtaining a copy of

View file

@ -63,7 +63,7 @@ Indicates the default path to an HDF5 file that contains multi-group cross
section libraries if the user has not specified the <cross_sections> tag in
.I materials.xml\fP.
.SH LICENSE
Copyright \(co 2011-2024 Massachusetts Institute of Technology, UChicago
Copyright \(co 2011-2025 Massachusetts Institute of Technology, UChicago
Argonne LLC, and OpenMC contributors.
.PP
Permission is hereby granted, free of charge, to any person obtaining a copy of