[latex3-commits] [git/LaTeX3-latex3-latex3] master: Internal function for shell operations (dcbed19)
Joseph Wright
joseph.wright at morningstar2.co.uk
Thu Jul 26 20:06:04 CEST 2018
Repository : https://github.com/latex3/latex3
On branch : master
Link : https://github.com/latex3/latex3/commit/dcbed19a3146cee41146b15b469274d861a9b5d0
>---------------------------------------------------------------
commit dcbed19a3146cee41146b15b469274d861a9b5d0
Author: Joseph Wright <joseph.wright at morningstar2.co.uk>
Date: Thu Jul 26 18:36:17 2018 +0100
Internal function for shell operations
>---------------------------------------------------------------
dcbed19a3146cee41146b15b469274d861a9b5d0
l3kernel/l3candidates.dtx | 33 +++++++++++++++++++++++++++++++
l3kernel/testfiles/m3expl001.luatex.tlg | 3 +++
l3kernel/testfiles/m3expl001.ptex.tlg | 3 +++
l3kernel/testfiles/m3expl001.tlg | 3 +++
l3kernel/testfiles/m3expl001.uptex.tlg | 3 +++
l3kernel/testfiles/m3expl001.xetex.tlg | 3 +++
l3kernel/testfiles/m3expl003.luatex.tlg | 3 +++
l3kernel/testfiles/m3expl003.ptex.tlg | 3 +++
l3kernel/testfiles/m3expl003.tlg | 3 +++
l3kernel/testfiles/m3expl003.uptex.tlg | 3 +++
l3kernel/testfiles/m3expl003.xetex.tlg | 3 +++
11 files changed, 63 insertions(+)
diff --git a/l3kernel/l3candidates.dtx b/l3kernel/l3candidates.dtx
index 7bdd10f..0bc5668 100644
--- a/l3kernel/l3candidates.dtx
+++ b/l3kernel/l3candidates.dtx
@@ -2999,6 +2999,39 @@
% \end{macrocode}
% \end{macro}
%
+% \begin{macro}[EXP]{\@@_path_to_win:n}
+% \begin{macro}[EXP]{\@@_path_to_win:w}
+% \begin{macro}[EXP]{\@@_path_to_win:N}
+% A simple expandable search-and-replace for providing Windows-style paths.
+% \begin{macrocode}
+\cs_new:Npn \@@_path_to_win:n #1
+ {
+ \exp_after:wN \@@_path_to_win:w \tl_to_str:n {#1} ~ \q_stop
+ }
+\cs_new:Npn \@@_path_to_win:w #1 ~ #2 \q_stop
+ {
+ \@@_path_to_win:N #1 \q_nil
+ \tl_if_empty:nF {#2}
+ {
+ \c_space_tl
+ \@@_path_to_win:w #2 \q_stop
+ }
+ }
+\cs_new:Npn \@@_path_to_win:N #1
+ {
+ \quark_if_nil:NF #1
+ {
+ \token_if_eq_meaning:NNTF #1 /
+ { \c_backslash_str }
+ {#1}
+ \@@_path_to_win:N
+ }
+ }
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
% \subsection{Additions to \pkg{l3tl}}
%
% \begin{macrocode}
diff --git a/l3kernel/testfiles/m3expl001.luatex.tlg b/l3kernel/testfiles/m3expl001.luatex.tlg
index b51c6f1..2136175 100644
--- a/l3kernel/testfiles/m3expl001.luatex.tlg
+++ b/l3kernel/testfiles/m3expl001.luatex.tlg
@@ -5850,6 +5850,9 @@ Defining \sys_shell_now:n on line ...
Defining \sys_shell_now:x on line ...
Defining \sys_shell_shipout:n on line ...
Defining \sys_shell_shipout:x on line ...
+Defining \__sys_path_to_win:n on line ...
+Defining \__sys_path_to_win:w on line ...
+Defining \__sys_path_to_win:N on line ...
Defining \tl_if_single_token_p:n on line ...
Defining \tl_if_single_token:nT on line ...
Defining \tl_if_single_token:nF on line ...
diff --git a/l3kernel/testfiles/m3expl001.ptex.tlg b/l3kernel/testfiles/m3expl001.ptex.tlg
index 7182773..8f1a560 100644
--- a/l3kernel/testfiles/m3expl001.ptex.tlg
+++ b/l3kernel/testfiles/m3expl001.ptex.tlg
@@ -5884,6 +5884,9 @@ Defining \sys_shell_now:n on line ...
Defining \sys_shell_now:x on line ...
Defining \sys_shell_shipout:n on line ...
Defining \sys_shell_shipout:x on line ...
+Defining \__sys_path_to_win:n on line ...
+Defining \__sys_path_to_win:w on line ...
+Defining \__sys_path_to_win:N on line ...
Defining \tl_if_single_token_p:n on line ...
Defining \tl_if_single_token:nT on line ...
Defining \tl_if_single_token:nF on line ...
diff --git a/l3kernel/testfiles/m3expl001.tlg b/l3kernel/testfiles/m3expl001.tlg
index 508bc61..5b72b23 100644
--- a/l3kernel/testfiles/m3expl001.tlg
+++ b/l3kernel/testfiles/m3expl001.tlg
@@ -5884,6 +5884,9 @@ Defining \sys_shell_now:n on line ...
Defining \sys_shell_now:x on line ...
Defining \sys_shell_shipout:n on line ...
Defining \sys_shell_shipout:x on line ...
+Defining \__sys_path_to_win:n on line ...
+Defining \__sys_path_to_win:w on line ...
+Defining \__sys_path_to_win:N on line ...
Defining \tl_if_single_token_p:n on line ...
Defining \tl_if_single_token:nT on line ...
Defining \tl_if_single_token:nF on line ...
diff --git a/l3kernel/testfiles/m3expl001.uptex.tlg b/l3kernel/testfiles/m3expl001.uptex.tlg
index 5c79f45..95ed152 100644
--- a/l3kernel/testfiles/m3expl001.uptex.tlg
+++ b/l3kernel/testfiles/m3expl001.uptex.tlg
@@ -5881,6 +5881,9 @@ Defining \sys_shell_now:n on line ...
Defining \sys_shell_now:x on line ...
Defining \sys_shell_shipout:n on line ...
Defining \sys_shell_shipout:x on line ...
+Defining \__sys_path_to_win:n on line ...
+Defining \__sys_path_to_win:w on line ...
+Defining \__sys_path_to_win:N on line ...
Defining \tl_if_single_token_p:n on line ...
Defining \tl_if_single_token:nT on line ...
Defining \tl_if_single_token:nF on line ...
diff --git a/l3kernel/testfiles/m3expl001.xetex.tlg b/l3kernel/testfiles/m3expl001.xetex.tlg
index 7d31f9c..e647653 100644
--- a/l3kernel/testfiles/m3expl001.xetex.tlg
+++ b/l3kernel/testfiles/m3expl001.xetex.tlg
@@ -5854,6 +5854,9 @@ Defining \sys_shell_now:n on line ...
Defining \sys_shell_now:x on line ...
Defining \sys_shell_shipout:n on line ...
Defining \sys_shell_shipout:x on line ...
+Defining \__sys_path_to_win:n on line ...
+Defining \__sys_path_to_win:w on line ...
+Defining \__sys_path_to_win:N on line ...
Defining \tl_if_single_token_p:n on line ...
Defining \tl_if_single_token:nT on line ...
Defining \tl_if_single_token:nF on line ...
diff --git a/l3kernel/testfiles/m3expl003.luatex.tlg b/l3kernel/testfiles/m3expl003.luatex.tlg
index b51c6f1..2136175 100644
--- a/l3kernel/testfiles/m3expl003.luatex.tlg
+++ b/l3kernel/testfiles/m3expl003.luatex.tlg
@@ -5850,6 +5850,9 @@ Defining \sys_shell_now:n on line ...
Defining \sys_shell_now:x on line ...
Defining \sys_shell_shipout:n on line ...
Defining \sys_shell_shipout:x on line ...
+Defining \__sys_path_to_win:n on line ...
+Defining \__sys_path_to_win:w on line ...
+Defining \__sys_path_to_win:N on line ...
Defining \tl_if_single_token_p:n on line ...
Defining \tl_if_single_token:nT on line ...
Defining \tl_if_single_token:nF on line ...
diff --git a/l3kernel/testfiles/m3expl003.ptex.tlg b/l3kernel/testfiles/m3expl003.ptex.tlg
index 7182773..8f1a560 100644
--- a/l3kernel/testfiles/m3expl003.ptex.tlg
+++ b/l3kernel/testfiles/m3expl003.ptex.tlg
@@ -5884,6 +5884,9 @@ Defining \sys_shell_now:n on line ...
Defining \sys_shell_now:x on line ...
Defining \sys_shell_shipout:n on line ...
Defining \sys_shell_shipout:x on line ...
+Defining \__sys_path_to_win:n on line ...
+Defining \__sys_path_to_win:w on line ...
+Defining \__sys_path_to_win:N on line ...
Defining \tl_if_single_token_p:n on line ...
Defining \tl_if_single_token:nT on line ...
Defining \tl_if_single_token:nF on line ...
diff --git a/l3kernel/testfiles/m3expl003.tlg b/l3kernel/testfiles/m3expl003.tlg
index 508bc61..5b72b23 100644
--- a/l3kernel/testfiles/m3expl003.tlg
+++ b/l3kernel/testfiles/m3expl003.tlg
@@ -5884,6 +5884,9 @@ Defining \sys_shell_now:n on line ...
Defining \sys_shell_now:x on line ...
Defining \sys_shell_shipout:n on line ...
Defining \sys_shell_shipout:x on line ...
+Defining \__sys_path_to_win:n on line ...
+Defining \__sys_path_to_win:w on line ...
+Defining \__sys_path_to_win:N on line ...
Defining \tl_if_single_token_p:n on line ...
Defining \tl_if_single_token:nT on line ...
Defining \tl_if_single_token:nF on line ...
diff --git a/l3kernel/testfiles/m3expl003.uptex.tlg b/l3kernel/testfiles/m3expl003.uptex.tlg
index 5c79f45..95ed152 100644
--- a/l3kernel/testfiles/m3expl003.uptex.tlg
+++ b/l3kernel/testfiles/m3expl003.uptex.tlg
@@ -5881,6 +5881,9 @@ Defining \sys_shell_now:n on line ...
Defining \sys_shell_now:x on line ...
Defining \sys_shell_shipout:n on line ...
Defining \sys_shell_shipout:x on line ...
+Defining \__sys_path_to_win:n on line ...
+Defining \__sys_path_to_win:w on line ...
+Defining \__sys_path_to_win:N on line ...
Defining \tl_if_single_token_p:n on line ...
Defining \tl_if_single_token:nT on line ...
Defining \tl_if_single_token:nF on line ...
diff --git a/l3kernel/testfiles/m3expl003.xetex.tlg b/l3kernel/testfiles/m3expl003.xetex.tlg
index 7d31f9c..e647653 100644
--- a/l3kernel/testfiles/m3expl003.xetex.tlg
+++ b/l3kernel/testfiles/m3expl003.xetex.tlg
@@ -5854,6 +5854,9 @@ Defining \sys_shell_now:n on line ...
Defining \sys_shell_now:x on line ...
Defining \sys_shell_shipout:n on line ...
Defining \sys_shell_shipout:x on line ...
+Defining \__sys_path_to_win:n on line ...
+Defining \__sys_path_to_win:w on line ...
+Defining \__sys_path_to_win:N on line ...
Defining \tl_if_single_token_p:n on line ...
Defining \tl_if_single_token:nT on line ...
Defining \tl_if_single_token:nF on line ...
More information about the latex3-commits
mailing list