[Dune-devel] "Dynamic" module version

Santiago Ospina De Los Rios santiago.ospina at iwr.uni-heidelberg.de
Tue Jul 13 13:08:13 CEST 2021


Hi Rene,


from what I have gathered from the CMake modernization, the dune.module is used to create a dependency DAG in CMake as well as in dunecontrol. Thus, I would only modify the version directly in the file instead of doing some sort of magic in CMake... Naturally, you can always write a pattern matching script in python that modifies the version at will (Example https://gitlab.dune-project.org/copasi/dune-copasi/-/blob/ff426165a550c838a77f71fd9413b43874e53140/util/bump_version.py#L32<https://gitlab.dune-project.org/copasi/dune-copasi/-/blob/ff426165a550c838a77f71fd9413b43874e53140/util/bump_version.py#L35>). I use it to bump versions, but nothing stops you from updating it in the CI directly. Just be aware that removing a pre-defined version from the dune.module will make your users to be dependent on having git and the scripting language you used to write the version (e.g. python). IMHO, this dependency is not desirable.


Hope it helps :)


Best,

Santiago

________________________________
From: Dune-devel <dune-devel-bounces at lists.dune-project.org> on behalf of René Fritze <rene.fritze at wwu.de>
Sent: Monday, July 12, 2021 9:57:35 AM
To: dune-devel at lists.dune-project.org
Subject: [Dune-devel] "Dynamic" module version

Dear all,

I'm wondering if anybody is already using a mechanism to override the static
"Version" field that Cmake reads from dune.module into `MODULE_NAME_VERSION`.
I'm looking to either set this from something like git describe or an
environment variable in CI, depending on release/dev pipeline etc.

Cheers,
René

--
--------------------------------------------------
 Dipl.-Math. René Fritze (né Milk)
 University of Münster
 Institute for Applied Mathematics
 Orleans-Ring 10, R. 120.012
 48149 Münster               Tel. +49 251 83-35131
 Germany
--------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.dune-project.org/pipermail/dune-devel/attachments/20210713/cce73cb3/attachment.htm>


More information about the Dune-devel mailing list