blob: c61d07ce94cf2a2ad2b7bdbdac1bfa0a7aa92d71 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
|
% \iffalse
%% File: l3vers.dtx Copyright (C) 1990-2009 LaTeX3 project
%%
%% It may be distributed and/or modified under the conditions of the
%% LaTeX Project Public License (LPPL), either version 1.3c of this
%% license or (at your option) any later version. The latest version
%% of this license is in the file
%%
%% http://www.latex-project.org/lppl.txt
%%
%% This file is part of the ``expl3 bundle'' (The Work in LPPL)
%% and all files in that bundle must be distributed together.
%%
%% The released version of this bundle is available from CTAN.
%%
%% -----------------------------------------------------------------------
%%
%% The development version of the bundle can be found at
%%
%% http://www.latex-project.org/svnroot/experimental/trunk/
%%
%% for those people who are interested.
%%
%%%%%%%%%%%
%% NOTE: %%
%%%%%%%%%%%
%%
%% Snapshots taken from the repository represent work in progress and may
%% not work or may contain conflicting material! We therefore ask
%% people _not_ to put them into distributions, archives, etc. without
%% prior consultation with the LaTeX Project Team.
%%
%% -----------------------------------------------------------------------
%<*driver|package>
\RequirePackage{l3names}
%</driver|package>
%\fi
\GetIdInfo$Id: l3vers.dtx 1378 2009-06-01 19:15:56Z joseph $
{L3 Experimental LaTeX format version}
%\iffalse
%<*driver>
%\fi
\ProvidesFile{\filename.\filenameext}
[\filedate\space v\fileversion\space\filedescription]
%\iffalse
\documentclass[full]{l3doc}
\begin{document}
\DocInput{\filename.\filenameext}
\end{document}
%</driver>
% \fi
%
% \begin{documentation}
%
% \section{Version Identification}
% Here we identify the date and version number of this release of
% \LaTeX3, and set |\tex_everyjob:D| so that it is printed at the start of
% every \LaTeX3 run.
%
% \begin{variable}{\c_format_name|\c_format_date}
% Name and date.
% \end{variable}
%
% \begin{variable}{\c_fmt_too_old}
% Age in months past "\c_format_date" after which an error is called
% during format generation.
% \end{variable}
%
% \begin{function}{\chk_format_age:w}
% Function that calculates the age of the format and calls an error if it
% is too old.
% \end{function}
%
% \end{documentation}
%
% \begin{implementation}
%
% \begin{macro}{\c_format_name}
% \begin{macro}{\c_format_date}
% \begin{macrocode}
%<*initex>
\cs_set_nopar:Npn\c_format_name{Experimental~ LaTeX3}
\cs_set_nopar:Npn\c_format_date{2009/06/01}
%^^A\cs_set_nopar:Npx\c_format_version{--release--date--goes--here--}
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\c_fmt_too_old}
% \begin{macro}{\chk_format_age:w}
% Check that the format being made is not too old. While in development
% it should be a rather small number.
% \begin{macrocode}
\int_const:Nn \c_fmt_too_old{12}
\cs_set_nopar:Npn\chk_format_age:w #1/#2/#3\q_stop{
% \end{macrocode}
% We just calculate the age of this file in months and give a warning
% if deemed too old.
% \begin{macrocode}
\intexpr_compare:nNnT{(\tex_year:D-#1)*12+\tex_month:D-#2}>\c_fmt_too_old
{\iow_term:x{^^J
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!^^J
!~~You~are~attempting~to~make~an~experimental~LaTeX3~format~from^^J
!~~source~files~that~are~more~than~
\intexpr_eval:n{\c_fmt_too_old}~months~old.^^J
!^^J
!~~If~you~enter~<return>~to~scroll~past~this~message~then~the~format^^J
!~~will~be~built,~but~please~consider~obtaining~newer~source~files^^J
!~~before~continuing~to~build~an~experimental~LaTeX3~format.^^J
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!^^J
}
\tex_errhelp:D{
To~avoid~this~error~message,~obtain~new~Experimental~LaTeX3~sources.}
\tex_errmessage:D{
Experimental~LaTeX3~source~files~are~more~than~
\intexpr_eval:n{\c_fmt_too_old}~months~old!}
}
}
% \end{macrocode}
% \end{macro}
% \end{macro}
% Then we execute it.
% \begin{macrocode}
\exp_after:wN\chk_format_age:w\c_format_date\q_stop
% \end{macrocode}
% And since it's no longer needed we remove it again.
% \begin{macrocode}
\cs_gundefine:N \chk_format_age:w
% \end{macrocode}
%
% This startup banner may be further modified by the code in
% |ltfinal.dtx| if a patch file is present.
% \begin{macrocode}
\tex_everyjob:D{\iow_term:x{\c_format_name,~<\c_format_date>}}
\iow_term:x{\c_format_name,~<\c_format_date>}
%</initex>
% \end{macrocode}
%
% \end{implementation}
% \PrintIndex
%
% \endinput
|