Backslashes not escaped after #3071
See original GitHub issueDescription
Today I upgraded from Fake 5-beta018 to beta020 because of the broken intellisense in VSCode. (fsharp/fake#1744). With this change the forward slashes in intellisense.fsx are replaced with single back slashes.
Repro steps
Please provide the steps required to reproduce the problem
-
Upgrade Fake 5 from beta018 to beta020
-
Delete [script_name.fsx].lock file
-
Call fake.cmd, such that a restore is triggert
-
Open directory in Ionide
Expected behavior
Expected output:
#if !FAKE
#r "C:/Users/jarno/.nuget/packages/fake.core.xml/5.0.0-beta018/lib/net46/Fake.Core.Xml.dll"
Actual behavior
Actual output:
#if !FAKE
#r "C:\Users\jarno\.nuget\packages\fake.core.xml\5.0.0-beta020\lib\net46\Fake.Core.Xml.dll"
Known workarounds
Possible workarounds are:
- Replacing the
\
with/
- Escape the
\
with a extra\
Example:
#if !FAKE
#r "C:\\Users\\jarno\\.nuget\\packages\\fake.core.xml\\5.0.0-beta020\\lib\\net46\\Fake.Core.Xml.dll"
Issue Analytics
- State:
- Created 6 years ago
- Comments:7 (7 by maintainers)
Top Results From Across the Web
How to escape with backslash only not escaped characters
1 Answer. Use re. sub() to capture all occurrences of the characters you want to escape that isn't prefixed by a slash \...
Read more >Escaping both forward slash and back slash with sed
If one wants to stick with slash as a separator and use double quotes then all escaped backslashes have to be escaped one...
Read more >Why does `echo -e "\\\SOME_TEXT"` show only one ...
A non-quoted backslash ( \ ) is the escape character. It preserves the literal value of the next character that follows, with the...
Read more >1638: Backslashes
To avoid this problem, an escape character (usually a backslash) is prepended to non-string-terminating quotes. So, the previous text would be written as ......
Read more >addslashes - Manual
Returns a string with backslashes added before characters that need to be escaped. These characters are: single quote ( ' ); double quote...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
+45 −18 is still kind of review-able 😉
that one gets huge 😉