Sujet : Re: is it possible to programmatically access Tcllib and Tklib versions?
De : wortkarg3 (at) *nospam* yahoo.com (Harald Oehlmann)
Groupes : comp.lang.tclDate : 27. Jun 2024, 18:35:49
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <v5k7tl$2r9ec$1@dont-email.me>
References : 1 2 3
User-Agent : Mozilla Thunderbird
Am 27.06.2024 um 07:37 schrieb Mark Summerfield:
On Wed, 26 Jun 2024 16:31:58 -0000 (UTC), Rich wrote:
Mark Summerfield <mark@qtrac.eu> wrote:
For a --help option or for an About box I like to show lib versions.
This is easy for Tcl and for Tk, e.g.
>
"Tcl v$::tcl_patchLevel/Tk v$::tk_version"
>
But I can't see how to get the versions of Tcllib and Tklib. Is this
possible?
>
I don't think so, as each module within tcllib is separately versioned.
>
You can show the versions by either capturing the return from package
require, or by rerunning package require at the time you want the data:
>
$ rlwrap tclsh % package require cmdline 1.5.2 % set cmdline_ver
[package require cmdline]
1.5.2 % puts "cmdline version is $cmdline_ver" cmdline version is
1.5.2 %
Ok, understood. Thanks.
No, there is something. I asked this question and Andreas added something.
https://core.tcl-lang.org/tcllib/info/13fc0520a654f9e9No, it is not included. But we recently have code to also include the fossil checkout id.
Here is the code by Alex:
https://fossil.sowaswie.de/ooxml/info/424958a4c5506180I will add this to the tcllib ticket...
Harald