summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/currfile/currfile.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/currfile/currfile.dtx')
-rw-r--r--macros/latex/contrib/currfile/currfile.dtx29
1 files changed, 20 insertions, 9 deletions
diff --git a/macros/latex/contrib/currfile/currfile.dtx b/macros/latex/contrib/currfile/currfile.dtx
index 5f677130a0..539c8dc728 100644
--- a/macros/latex/contrib/currfile/currfile.dtx
+++ b/macros/latex/contrib/currfile/currfile.dtx
@@ -1,7 +1,7 @@
% \iffalse meta-comment
%<=*COPYRIGHT>
%%
-%% Copyright (c) 2010-2020 by Martin Scharrer <martin@scharrer-online.de>
+%% Copyright (c) 2010-2022 by Martin Scharrer <martin.scharrer@web.de>
%% ----------------------------------------------------------------------
%%
%% This work may be distributed and/or modified under the
@@ -29,10 +29,10 @@
\NeedsTeXFormat{LaTeX2e}[1999/12/01]
\ProvidesFile{currfile.dtx}[%
%<=*DATE>
- 2020/09/29
+ 2022/10/10
%<=/DATE>
%<=*VERSION>
- v0.7d
+ v0.8
%<=/VERSION>
DTX file for currfile package]
@@ -59,7 +59,7 @@
%</driver>
% \fi
%
-% \CheckSum{1114}
+% \CheckSum{1115}
%
% \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
@@ -91,6 +91,7 @@
% \changes{v0.7b}{2013/02/01}{Support for \cs{\subinput*} etc.\ from the \pkg{import} package which requires a different path search order.}
% \changes{v0.7c}{2015/04/23}{Removed stack underflow warning if loaded by other package. Set default file name in this case to main file name.}
% \changes{v0.7d}{2020/09/29}{Updated documentation for 2020/10/01 \LaTeX\ release.}
+% \changes{v0.8}{2022/10/10}{Fixed issue with filename with spaces.}
%
%
% \GetFileInfo{currfile.dtx}
@@ -103,8 +104,8 @@
% \DoNotIndex{\message,\jobname,\@namedef}
%
% \author{Martin Scharrer}
-% \email{martin@scharrer-online.de}
-% \repository{https://sourceforge.net/projects/currfile/}
+% \email{martin.scharrer@web.de}
+% \repository{https://github.com/MartinScharrer/currfile}
% \maketitle
%
% \begin{abstract}
@@ -529,6 +530,16 @@
% \end{macro}
%
%
+% \begin{macro}{\currfile@openin}[2]{file handle}{file path}
+% Opens the given file for reading.
+% \begin{macrocode}
+\def\currfile@openin#1#2{%
+\openin#1="#2"\relax
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
% \begin{macro}{\currfile@checkpath}
% This loop is placed in an own macro for efficiency reasons.
% In the majority of cases it should not be needed and having it as
@@ -537,7 +548,7 @@
% \changes{2011/09/18}{v0.5}{New macro as part of the \cs{input@path} support.}
% \begin{macrocode}
\def\currfile@checkpath{%
- \openin\@inputcheck\@filef@und\relax
+\currfile@openin{\@inputcheck}{\@filef@und}%
\ifeof\@inputcheck
\currfile@check@inputpath
\fi
@@ -554,7 +565,7 @@
\expandafter\@tfor
\expandafter\@tempb
\expandafter:\expandafter=\input@path\do{%
- \openin\@inputcheck\@tempb\@filef@und\relax
+\currfile@openin{\@inputcheck}{\@tempb\@filef@und}%
\ifeof\@inputcheck\else
\edef\@filef@und{\@tempb\@filef@und}%
\@break@tfor
@@ -572,7 +583,7 @@
\ifx\IfFileExists\@iffileonpath
\currfile@check@inputpath
\else
- \openin\@inputcheck\@filef@und\relax
+\currfile@openin{\@inputcheck}{\@filef@und}%
\ifeof\@inputcheck
\currfile@check@inputpath
\fi