Skip to content

Commit

Permalink
QueryWorkingDirectory
Browse files Browse the repository at this point in the history
  • Loading branch information
davidcarlisle committed Mar 11, 2024
1 parent 5f95f83 commit 6532f21
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
6 changes: 3 additions & 3 deletions l3sys-query.sty
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

% Defines:

% \QueryPWD {<result>}
% \QueryWorkingDirectory {<result>}
% defines the command passed in as #1 to be the current working directory

% \QueryFiles[<options>]{<args>}{function}
Expand All @@ -20,8 +20,8 @@

\ExplSyntaxOn

\NewDocumentCommand\QueryPWD {m} {
\sys_get_query:nnnN {pwd} {} {} #1
\NewDocumentCommand\QueryWorkingDirectory {m} {
\sys_get_query:nN {pwd} #1
}

\NewDocumentCommand\QueryFiles {} {
Expand Down
3 changes: 2 additions & 1 deletion test-2e-01.tex
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@



\QueryPWD \thisdir
\QueryWorkingDirectory \thisdir

\typeout{PWD: \thisdir}


\QueryFiles{*.tex}{\typeout{A: #1}}

\QueryFiles[recursive,type=d]{}{\typeout{B: #1}}% . ought to work
Expand Down

0 comments on commit 6532f21

Please sign in to comment.