Re: Regression: Problem with Paths Containing ~ [Was Re: LyX 2.3.3 Error with iCloud Folders]
Am Sonntag, den 07.07.2019, 13:08 -0400 schrieb Richard Kimberly Heck: > No problems with any of those. OK, thanks for verifying. Jürgen signature.asc Description: This is a digitally signed message part
Re: Regression: Problem with Paths Containing ~ [Was Re: LyX 2.3.3 Error with iCloud Folders]
On 7/7/19 4:39 AM, Jürgen Spitzmüller wrote: > Am Samstag, den 06.07.2019, 15:16 -0400 schrieb Richard Kimberly Heck: >> Fine by me. > I took this as also including stable, so I committed and backported. > > There are other (active) ASCII characters that might be worth checking, > specifically @, #, $, % and &. No problems with any of those. Riki
Re: Regression: Problem with Paths Containing ~ [Was Re: LyX 2.3.3 Error with iCloud Folders]
Am Samstag, den 06.07.2019, 15:16 -0400 schrieb Richard Kimberly Heck: > Fine by me. I took this as also including stable, so I committed and backported. There are other (active) ASCII characters that might be worth checking, specifically @, #, $, % and &. Jürgen signature.asc Description: This is a digitally signed message part
Re: Regression: Problem with Paths Containing ~ [Was Re: LyX 2.3.3 Error with iCloud Folders]
Am 06.07.2019 um 11:57 schrieb Jürgen Spitzmüller : > > Am Mittwoch, den 03.07.2019, 15:53 -0400 schrieb Richard Kimberly Heck: >> Same problem. I've traced it to: >> >> \def\input@path{{/home/rikiheck/this~silly~dir/}} >> >> It appears to be that LaTeX itself has problems with such paths. If >> we >> add \detokenize: >> >> \def\input@path{{\detokenize{/home/rikiheck/this~silly~dir/}}} >> >> then it works. >> >> In 2.3.2, we get: >> >> \def\input@path{{/home/rikiheck/this\string~silly\string~dir/}} > > Note that the \string solution does not work any longer with recent > LaTeX. > >> >> This seems to be a regression in ac351f40f1d1. We used to call >> support::latex_path here, but now only call os::latex_path, and the >> result is that ~ doesn't get '\string'd. I would guess that there may >> be >> similar problems with other characters that are handled there. > > \detokenize is only omitted for ASCII characters, so it seems > worthwhile to handle just that special case (and add others if it turns > out to be necessary). > > Like in the attached patch. > > Jürgen > >> >> Note that this is also in master. > This works for me. Stephan
Re: Regression: Problem with Paths Containing ~ [Was Re: LyX 2.3.3 Error with iCloud Folders]
On 7/6/19 5:57 AM, Jürgen Spitzmüller wrote: > Am Mittwoch, den 03.07.2019, 15:53 -0400 schrieb Richard Kimberly Heck: >> Same problem. I've traced it to: >> >> \def\input@path{{/home/rikiheck/this~silly~dir/}} >> >> It appears to be that LaTeX itself has problems with such paths. If >> we >> add \detokenize: >> >> \def\input@path{{\detokenize{/home/rikiheck/this~silly~dir/}}} >> >> then it works. >> >> In 2.3.2, we get: >> >> \def\input@path{{/home/rikiheck/this\string~silly\string~dir/}} > Note that the \string solution does not work any longer with recent > LaTeX. > >> This seems to be a regression in ac351f40f1d1. We used to call >> support::latex_path here, but now only call os::latex_path, and the >> result is that ~ doesn't get '\string'd. I would guess that there may >> be >> similar problems with other characters that are handled there. > \detokenize is only omitted for ASCII characters, so it seems > worthwhile to handle just that special case (and add others if it turns > out to be necessary). > > Like in the attached patch. Fine by me. Riki
Re: Regression: Problem with Paths Containing ~ [Was Re: LyX 2.3.3 Error with iCloud Folders]
Am Mittwoch, den 03.07.2019, 15:53 -0400 schrieb Richard Kimberly Heck: > Same problem. I've traced it to: > > \def\input@path{{/home/rikiheck/this~silly~dir/}} > > It appears to be that LaTeX itself has problems with such paths. If > we > add \detokenize: > > \def\input@path{{\detokenize{/home/rikiheck/this~silly~dir/}}} > > then it works. > > In 2.3.2, we get: > > \def\input@path{{/home/rikiheck/this\string~silly\string~dir/}} Note that the \string solution does not work any longer with recent LaTeX. > > This seems to be a regression in ac351f40f1d1. We used to call > support::latex_path here, but now only call os::latex_path, and the > result is that ~ doesn't get '\string'd. I would guess that there may > be > similar problems with other characters that are handled there. \detokenize is only omitted for ASCII characters, so it seems worthwhile to handle just that special case (and add others if it turns out to be necessary). Like in the attached patch. Jürgen > > Note that this is also in master. diff --git a/src/Buffer.cpp b/src/Buffer.cpp index f1455ddd90..2e467d589b 100644 --- a/src/Buffer.cpp +++ b/src/Buffer.cpp @@ -1931,7 +1931,8 @@ Buffer::ExportStatus Buffer::writeLaTeXSource(otexstream & os, os << "\\catcode`\\%=11" "\\def\\%{%}\\catcode`\\%=14\n"; } -bool const detokenize = !isAscii(from_utf8(docdir)); +bool const detokenize = !isAscii(from_utf8(docdir)) + || contains(docdir, '~'); bool const quote = contains(docdir, ' '); os << "\\makeatletter\n" << "\\def\\input@path{{"; signature.asc Description: This is a digitally signed message part