From: Simon Pepping <spepping@scaprea.hobby.nl>
Subject: Re: getting context's version
Date: Thu, 19 Sep 2002 20:41:27 +0200 [thread overview]
Message-ID: <20020919204127.A861@scaprea> (raw)
In-Reply-To: <Pine.LNX.4.42.0209181351080.7905-100000@servalys.nl>; from wybo@servalys.nl on Wed, Sep 18, 2002 at 05:28:13PM +0200
This sounds like you want to make sure that you run a specific minimal
context version. In latex this may be checked by the macro code:
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{article}
[2000/05/19 v1.4b
Standard LaTeX document class]
and then when you say \documentclass{article}[2002/06/01], latex warns
you that you run an older version than required. This is a solution at
the root, so I think it is the way to go.
Simon
On Wed, Sep 18, 2002 at 05:28:13PM +0200, Wybo Dekker wrote:
> #!/usr/bin/perl -w
>
> sub test_context_version {
> my $required=shift;
> chomp (my $fmt=`kpsewhich cont-en.efmt`);
> chomp (my $tex=`kpsewhich context.tex`);
> (stat $fmt)[10] < (stat $tex)[10] and
> die "Your context formats need (re)generation:\n";
> open(IN,$tex) or do {
> warn "can't find context.tex";
> return 1;
> };
> while(<IN>) {
> if ( /contextversion\{(\d+)\.(\d+)\.(\d+)\}/ ) {
> my $have;
> $have=sprintf('%4d%02d%02d',$1,$2,$3);
> $have < $required and
> warn "Your ConTeXt is too old ($have); you need $required\n";
> return 1;
> last;
> }
> }
> return 0;
> }
--
Simon Pepping
email: spepping@scaprea.hobby.nl
next prev parent reply other threads:[~2002-09-19 18:41 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-09-17 10:07 Wybo Dekker
2002-09-17 18:00 ` Tobias Burnus
2002-09-17 18:23 ` Wybo Dekker
2002-09-18 6:57 ` Hans Hagen
2002-09-18 8:41 ` Tobias Burnus
2002-09-18 8:59 ` Wybo Dekker
2002-09-18 9:17 ` Tobias Burnus
2002-09-18 9:47 ` Taco Hoekwater
2002-09-18 15:28 ` Wybo Dekker
2002-09-19 18:41 ` Simon Pepping [this message]
2002-09-20 8:06 ` Taco Hoekwater
2002-05-20 8:56 ` Hans Hagen
2002-09-20 9:32 ` Tobias Burnus
2002-05-20 14:42 ` Hans Hagen
2002-09-20 17:55 ` Henning Hraban Ramm
2002-09-21 17:29 ` Simon Pepping
2002-09-18 9:43 ` Taco Hoekwater
2002-09-17 18:28 ` Taco
2002-09-17 21:20 ` Wybo Dekker
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20020919204127.A861@scaprea \
--to=spepping@scaprea.hobby.nl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).