diff options
author | Karl Berry <karl@freefriends.org> | 2011-03-25 22:32:09 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2011-03-25 22:32:09 +0000 |
commit | 3e0da7063ec8c3bfc7455bfe9935bda3d82e9dc5 (patch) | |
tree | 5cd6b56bafe2f5d5920fd004bcf34a733343a9f6 /Master/texmf-dist/tex/latex/filemod/filemod-expmin.sty | |
parent | cfed44562985f2f168a5b2f6df46bcaec533d7e9 (diff) |
filemod (25mar11)
git-svn-id: svn://tug.org/texlive/trunk@21831 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/filemod/filemod-expmin.sty')
-rw-r--r-- | Master/texmf-dist/tex/latex/filemod/filemod-expmin.sty | 44 |
1 files changed, 39 insertions, 5 deletions
diff --git a/Master/texmf-dist/tex/latex/filemod/filemod-expmin.sty b/Master/texmf-dist/tex/latex/filemod/filemod-expmin.sty index beae7a20b60..85357bb09cd 100644 --- a/Master/texmf-dist/tex/latex/filemod/filemod-expmin.sty +++ b/Master/texmf-dist/tex/latex/filemod/filemod-expmin.sty @@ -15,21 +15,54 @@ %% This work consists of the files filemod.dtx and filemod.ins %% and the derived filebase filemod.sty. \ProvidesPackage{filemod-expmin}[% - 2011/03/23 v1.0 + 2011/03/24 v1.1 Get and compare file modification times (expandable; minimal)] +\ifx\filemod@directtrue\@undefined +\csname newif\expandafter\endcsname\csname iffilemod@direct\endcsname +\filemod@directtrue +\ifx\pdffilemoddate\@undefined + \RequirePackage{pdftexcmds} + \filemod@directfalse + \ifx\pdf@filemoddate\@undefined + \edef\filemod@help + {The required command \string\pdffilemoddate\space is not defined. + This means that the used\space\space LaTeX compiler does not support it. + Please make sure that pdfLaTeX 1.30.0 or\space\space\space newer or LuaLaTeX is used. + XeLaTeX does not support reading file modification\space\space dates. + }% + \PackageError{filemod}{Required command \string\pdffilemoddate\space is not defined!}{\filemod@help} + \fi +\fi +\fi \begingroup -\@makeother\D -\@makeother\Z -\@makeother: +\catcode`\D=12 +\catcode`\Z=12 +\catcode`\:=12 +\newcommand*\filemodNumdate{} +\iffilemod@direct \gdef\filemodNumdate#1{% \expandafter\filemod@Numdate\pdffilemoddate{#1}D:00000000000000Z\relax } +\else +\gdef\filemodNumdate#1{% + \expandafter\expandafter + \expandafter\filemod@Numdate\pdf@filemoddate{#1}D:00000000000000Z\relax +} +\fi \gdef\filemod@Numdate D:#1#2#3#4#5#6#7#8#9\relax{% #1#2#3#4#5#6#7#8% } +\newcommand*\filemodNumtime{} +\iffilemod@direct \gdef\filemodNumtime#1{% \expandafter\filemod@Numtime\pdffilemoddate{#1}D:00000000000000Z\relax } +\else +\gdef\filemodNumtime#1{% + \expandafter\expandafter + \expandafter\filemod@Numtime\pdf@filemoddate{#1}D:00000000000000Z\relax +} +\fi \gdef\filemod@Numtime D:#1#2#3#4#5#6#7#8#9\relax{% \filemod@@Numtime#9\relax } @@ -37,7 +70,8 @@ #1#2#3#4#5#6% } \endgroup -\newcommand*\filemodCmp[2]{% +\newcommand*\filemodCmp[2]% +{% \ifcase0% \ifnum\filemodNumdate{#2}>\filemodNumdate{#1} 1\else \ifnum\filemodNumdate{#2}=\filemodNumdate{#1} % |