summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2010-04-27 01:00:18 +0000
committerKarl Berry <karl@freefriends.org>2010-04-27 01:00:18 +0000
commite3e5b0d13853ec7695e9288b3702a052018b7812 (patch)
treef5d5a1e166072f1b6f71b9645d7e3e02dce5807a /Master/texmf-dist/source/latex
parent82ee4d7b302cb88448593a12e6fd2ae6b0539402 (diff)
svn-prov update (25apr10)
git-svn-id: svn://tug.org/texlive/trunk@18017 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex')
-rw-r--r--Master/texmf-dist/source/latex/svn-prov/Makefile144
-rw-r--r--Master/texmf-dist/source/latex/svn-prov/svn-prov.dtx75
2 files changed, 181 insertions, 38 deletions
diff --git a/Master/texmf-dist/source/latex/svn-prov/Makefile b/Master/texmf-dist/source/latex/svn-prov/Makefile
new file mode 100644
index 00000000000..2587581d4ea
--- /dev/null
+++ b/Master/texmf-dist/source/latex/svn-prov/Makefile
@@ -0,0 +1,144 @@
+# $Id: Makefile 1762 2010-03-26 15:46:08Z martin $
+
+PACKAGE = svn-prov
+PACKAGE_STY = ${PACKAGE}.sty
+PACKAGE_DTX = ${PACKAGE}.dtx
+PACKAGE_SCR =
+PACKAGE_DOC = $(PACKAGE_DTX:.dtx=.pdf)
+PACKAGE_SRC = ${PACKAGE_DTX} ${PACKAGE}.ins Makefile
+PACKFILES = ${PACKAGE_SRC} ${PACKAGE_DOC} README
+
+TEXAUX = *.aux *.log *.glo *.ind *.idx *.out *.svn *.svx *.svt *.toc *.ilg *.gls *.hd *.fdb_latexmk
+INSGENERATED = ${PACKAGE_STY}
+GENERATED = ${INSGENERATED} ${PACKAGE}.pdf ${PACKAGE}.zip ${PACKAGE}.tar.gz ${TESTDIR}/test*.pdf
+ZIPFILE = ${PACKAGE}-${ZIPVERSION}.zip
+TDSZIPFILE = ${PACKAGE}-${ZIPVERSION}.tds.zip
+
+TESTDIR = tests
+TESTS = $(patsubst %.tex,%,$(subst ${TESTDIR}/,,$(wildcard ${TESTDIR}/test?.tex ${TESTDIR}/test??.tex))) # look for all test*.tex file names and remove the '.tex'
+TESTARGS = -output-directory ${TESTDIR}
+
+LATEX_OPTIONS = -interaction=batchmode
+LATEX = pdflatex ${LATEX_OPTIONS}
+
+TEXMFDIR = ${HOME}/texmf
+
+RED = \033[01;31m
+GREEN = \033[01;32m
+WHITE = \033[00m
+
+CP = cp -v
+MV = mv -v
+RMDIR = rm -rf
+MKDIR = mkdir -p
+
+.PHONY: all doc package clean fullclean example testclean ${TESTS} tds ${CHECK_LOG}
+
+###############################################################################
+
+all: package doc example
+new: fullclean all
+
+doc: ${PACKAGE_DOC} pdfopt
+
+package: ${PACKAGE_STY} ${PACKAGE_SCR}
+
+%.pdf: %.dtx
+ ${LATEX} $*.dtx
+ -makeindex -s gind.ist -o $*.ind $*.idx
+ -makeindex -s gglo.ist -o $*.gls $*.glo
+ ${LATEX} $*.dtx
+ ${LATEX} $*.dtx
+
+${PACKAGE}.pdf: ${PACKAGE}.sty
+
+${INSGENERATED}: ${PACKAGE_DTX} ${PACKAGE}.ins
+ yes | latex ${PACKAGE}.ins
+
+clean:
+ rm -f ${TEXAUX} $(addprefix ${TESTDIR}/, ${TEXAUX})
+
+fullclean: clean
+ rm -f ${GENERATED} *~ *.backup
+ rm -f ${PACKAGE}*.zip
+ rm -rf tds/
+
+
+zip: ${PACKFILES}
+ @${MAKE} --no-print-directory ${ZIPFILE}
+
+zip: ZIPVERSION=$(shell grep "Package: ${PACKAGE} " ${PACKAGE}.log | \
+ sed -e "s/.*Package: ${PACKAGE} ....\/..\/..\s\+\(v\S\+\).*/\1/")
+
+tdszip: ZIPVERSION=$(shell grep "Package: ${PACKAGE} " ${PACKAGE}.log | \
+ sed -e "s/.*Package: ${PACKAGE} ....\/..\/..\s\+\(v\S\+\).*/\1/")
+
+${PACKAGE}%.zip: ${PACKFILES}
+ @test -n "${IGNORE_CHECKSUM}" || grep -L '\* Checksum passed \*' ${PACKAGE_DTX:.dtx=.log} | wc -l | grep -q '^0$$'
+ ${RM} $@
+ zip $@ ${PACKFILES}
+ @echo
+ @echo "ZIP file $@ created!"
+
+release: fullclean package doc example tests zip
+
+pdfopt: .${PACKAGE}.opt
+.${PACKAGE}.opt: ${PACKAGE}.pdf
+ -pdfopt "$<" "$@" && cp "$@" "$<" && touch --reference="$<" "$@"
+
+###############################################################################
+
+# Make sure TeX finds the input files in TESTDIR
+tests ${TESTS}: export TEXINPUTS:=${TEXINPUTS}:${TESTDIR}
+tests ${TESTS}: LATEX_OPTIONS=
+
+testclean:
+ @${RM} $(foreach ext, aux log out pdf svn svx, tests/test*.${ext})
+
+tests: package testclean
+ @echo "Running tests: ${TESTS}:"
+ @${MAKE} -e -i --no-print-directory ${TESTS} \
+ TESTARGS="-interaction=batchmode -output-directory=${TESTDIR}"\
+ TESTPLOPT="-q"\
+ > /dev/null
+
+${TESTS}: % : ${TESTDIR}/%.tex package testclean
+ @-${LATEX} -interaction=nonstopmode ${TESTARGS} $< 1>/dev/null 2>/dev/null
+ @if (${LATEX} ${TESTARGS} $< && (test ! -e ${TESTDIR}/$*.pl || ${TESTDIR}/$*.pl ${TESTPLOPT})); \
+ then /bin/echo -e "${GREEN}$@ succeeded${WHITE}" >&2; \
+ else /bin/echo -e "${RED}$@ failed!!!!!!${WHITE}" >&2; fi
+
+###############################################################################
+
+tds: .tds
+
+.tds: ${PACKAGE_STY} ${PACKAGE_DOC} ${PACKAGE_SRC}
+ @grep -q '\* Checksum passed \*' ${PACKAGE}.log
+ ${RMDIR} tds
+ ${MKDIR} tds/
+ ${MKDIR} tds/tex/ tds/tex/latex/ tds/tex/latex/${PACKAGE}/
+ ${MKDIR} tds/doc/ tds/doc/latex/ tds/doc/latex/${PACKAGE}/
+ ${MKDIR} tds/source/ tds/source/latex/ tds/source/latex/${PACKAGE}/
+ -test -n "${PACKAGE_SCR}" && ${MKDIR} tds/scripts/ tds/scripts/${PACKAGE}/
+ ${CP} ${PACKAGE_STY} tds/tex/latex/${PACKAGE}/
+ ${CP} ${PACKAGE_DOC} tds/doc/latex/${PACKAGE}/
+ -${CP} ${PACKAGE_SRC} tds/source/latex/${PACKAGE}/
+ -test -n "${PACKAGE_SCR}" && ${CP} ${PACKAGE_SCR} tds/scripts/${PACKAGE}/
+ @touch $@
+
+tdszip: ${TDSZIPFILE}
+
+${TDSZIPFILE}: .tds
+ ${RM} ${TDSZIPFILE}
+ cd tds && zip -r ../${TDSZIPFILE} .
+
+###############################################################################
+
+install: .tds
+ test -d "${TEXMFDIR}" && ${CP} -a tds/* "${TEXMFDIR}/" && texhash ${TEXMFDIR}
+
+uninstall:
+ test -d "${TEXMFDIR}" && ${RM} -rv "${TEXMFDIR}/tex/latex/${PACKAGE}" \
+ "${TEXMFDIR}/doc/latex/${PACKAGE}" "${TEXMFDIR}/source/latex/${PACKAGE}" \
+ "${TEXMFDIR}/scripts/${PACKAGE}" && texhash ${TEXMFDIR}
+
diff --git a/Master/texmf-dist/source/latex/svn-prov/svn-prov.dtx b/Master/texmf-dist/source/latex/svn-prov/svn-prov.dtx
index 616a5b3ec14..ff0066fab4e 100644
--- a/Master/texmf-dist/source/latex/svn-prov/svn-prov.dtx
+++ b/Master/texmf-dist/source/latex/svn-prov/svn-prov.dtx
@@ -1,5 +1,5 @@
% \iffalse meta-comment
-% $Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $
+% $Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $
%
% Copyright (C) 2009-2010 by Martin Scharrer <martin@scharrer-online.de>
%
@@ -30,7 +30,7 @@
\def\svnprov@version{v3.\rev}
%</driver|package>
%<*driver>
-\ProvidesFileSVN{$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+\ProvidesFileSVN{$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
[\svnprov@version\space DTX for \filebase.sty]
\DefineFileInfoSVN
\GetFileInfoSVN*
@@ -105,7 +105,7 @@
%</driver>
% \fi
%
-% \CheckSum{424}
+% \CheckSum{423}
%
% \CharacterTable
% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
@@ -171,7 +171,7 @@
% \meta{time} \meta{author} \$}
% \par\smallskip
% \noindent e.g. for the source file of this document:\par\smallskip
-% |$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $|
+% |$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $|
% \par\smallskip
% \noindent For this to work the Subversion \emph{property} \texttt{svn:keywords} must be
% set to (at least) `|Id|' for the source file(s). e.g.\ using the command
@@ -255,8 +255,9 @@
% classes). This default can be overwritten by the optional argument.
% The \meta{data} stands for |version|, |rev| (revision), |date| and |info|
% (the information part without the version number)
-% and, since v3,\marginpar{\it\raggedright Updated in v3. 2010/04/11}
-% file name |base| and |ext|(ension).
+% and, since v3,\marginpar{\it\raggedright Updated in v3. 2010/04/24}
+% file name |base| and |ext|(ension) as well as |today|, which prints
+% the |date| in the format of \cs{today}.
%
% \noindent
% \textit{Example:} Applied to the |.dtx| file of this very package the
@@ -273,6 +274,7 @@
% \cs{svn-prov.dtx@info} & \@nameuse{svn-prov.dtx@info} \\
% \cs{svn-prov.dtx@base} & \@nameuse{svn-prov.dtx@base} \\
% \cs{svn-prov.dtx@ext} & \@nameuse{svn-prov.dtx@ext} \\
+% \cs{svn-prov.dtx@today} & \@nameuse{svn-prov.dtx@today} \\
% \bottomrule
% \end{tabular}
% \par\bigskip
@@ -309,80 +311,80 @@
% \subsubsection*{Minimal usage}
% \begin{example}
% \ProvidesPackageSVN
-% {$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+% {$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
% \end{example}
% \begin{example}
% \ProvidesClassSVN
-% {$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+% {$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
% \end{example}
% \begin{example}
% \ProvidesFileSVN
-% {$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+% {$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
% \end{example}
%
% \subsubsection*{Normal Usage}
% \begin{example}
% \ProvidesPackageSVN
-% {$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+% {$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
% [v1.0 Example Description]
% \end{example}
% \begin{example}
% \ProvidesClassSVN
-% {$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+% {$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
% [v1.0 Example Description]
% \end{example}
% \begin{example}
% \ProvidesFileSVN
-% {$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+% {$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
% [v1.0 Example Description]
% \end{example}
%
% \subsubsection*{Normal Usage with only Description}
% \begin{example}
% \ProvidesFileSVN
-% {$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+% {$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
% [Example Description]
% \end{example}
%
% \subsubsection*{Normal Usage with separate Version and Description}
% \begin{example}
% \ProvidesFileSVN
-% {$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+% {$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
% [v1.0][Example Description]
% \end{example}
%
% \subsubsection*{Overwriting Name}
% \begin{example}
% \ProvidesPackageSVN[othername]
-% {$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+% {$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
% [v1.0 Example Description]
% \end{example}
%
% \subsubsection*{Overwriting Name including unneeded Extension}
% \begin{example}
% \ProvidesPackageSVN[othername.sty]
-% {$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+% {$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
% [v1.0 Example Description]
% \end{example}
%
% \subsubsection*{Overwriting Name using Macros}
% \begin{example}
% \ProvidesFileSVN[\filebase.cfg]
-% {$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+% {$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
% [v1.0 Example Description]
% \end{example}
%
% \subsubsection*{Using Macros in File Information String}
% \begin{example}
% \ProvidesPackageSVN
-% {$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+% {$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
% [v1.\Rev Example Description]
% \end{example}
%
% \subsubsection*{Adding Text to Default Information}
% \begin{example}
% \ProvidesPackageSVN
-% {$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+% {$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
% [v1.\Rev Extra Text \revinfo]
% \end{example}
%
@@ -392,7 +394,7 @@
%
% \begin{example}
% \ProvidesPackageSVN
-% {$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}
+% {$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}
% [v1.\Rev Extra Text \revinfo]
% \GetFileInfoSVN*
% % ...
@@ -523,6 +525,7 @@
\svnprov@splitfilename{#2}%
\def\svnprov@filerev@{#3}%
\def\svnprov@filedate@{#4/#5/#6}%
+ \def\svnprov@filetoday@{\svnprov@@today{#4}{#5}{#6}}%
\def\next{\begingroup\svnprov@catcodes\svnprov@buildstring}%
\fi
\fi
@@ -536,6 +539,15 @@
\endgroup
% \end{macrocode}
%
+% \begin{macro}{\svnprov@@today}
+% Prints \cs{today} with the given date.
+% \begin{macrocode}
+\def\svnprov@@today#1#2#3{%
+ {\year#1\month#2\day#3\relax\today}%
+}
+% \end{macrocode}
+% \end{macro}
+%
% \begin{macro}{\svnprov@splitfilename}
% Expands the argument and initialises the file base macro before it calls the
% next macro with the expanded argument and a dot to protect for \TeX\ parsing
@@ -679,7 +691,7 @@
\let\filerev\svnprov@filerev@
\let\fileversion\svnprov@fileversion@
\let\fileinfo\svnprov@filedesc@
- \expandafter\svnprov@settoday@\svnprov@filedate@\relax
+ \let\filetoday\svnprov@filetoday@
\else
% \end{macrocode}
% Given argument could be filename or short name.
@@ -699,27 +711,12 @@
\expandafter\let\expandafter\filerev \csname\@gtempa @rev\endcsname
\expandafter\let\expandafter\fileversion\csname\@gtempa @version\endcsname
\expandafter\let\expandafter\fileinfo\csname\@gtempa @info\endcsname
- \@ifundefined{\@gtempa @date}%
- {\def\filetoday{?}}%
- {\expandafter\expandafter\expandafter\svnprov@settoday@\csname\@gtempa @date\endcsname\relax}%
+ \expandafter\let\expandafter\filetoday\csname\@gtempa @today\endcsname
\fi
}
% \end{macrocode}
% \end{macro}
%
-% \begin{macro}{\svnprov@settoday@}
-% Sets \cs{filetoday} by expanding \cs{today} after setting the year/month/day locally.
-% \changes{v3.}{2010/04/14}{Changed to dynamically call \cs{today} and not use \cs{edef}, because \cs{today} might not defined (yet).}
-% \begin{macrocode}
-\def\svnprov@settoday@#1/#2/#3\relax{%
- \def\filetoday{{%
- \year#1\month#2\day#3\relax
- \today
- }}%
-}
-% \end{macrocode}
-% \end{macro}
-%
% \begin{macro}{\DefineFileInfoSVN}
% Defines macros in the form |\|\meta{filename}|@|\meta{xxx}, where \meta{xxx} is |date|, |version|, |rev|(ision), |info|, (file name)|base| and |ext|(ension).
% \changes{v3.}{2010/04/01}{Added file name `base' and 'ext'(ension).}
@@ -741,6 +738,8 @@
\let\csname#1@rev\endcsname\svnprov@filerev@
\expandafter
\let\csname#1@info\endcsname\svnprov@filedesc@
+ \expandafter
+ \let\csname#1@today\endcsname\svnprov@filetoday@
}
% \end{macrocode}
% \end{macro}
@@ -779,7 +778,7 @@
%
% Finally, call the macros for this package itself.
% \begin{macrocode}
-\ProvidesPackageSVN{$Id: svn-prov.dtx 1858 2010-04-14 18:30:31Z martin $}%
+\ProvidesPackageSVN{$Id: svn-prov.dtx 1862 2010-04-24 14:19:07Z martin $}%
[\svnprov@version\space Package Date/Version from SVN Keywords]
\DefineFileInfoSVN[svnprov]
% \end{macrocode}