question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Backslashes not escaped after #3071

See original GitHub issue

Description

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

  1. Upgrade Fake 5 from beta018 to beta020

  2. Delete [script_name.fsx].lock file

  3. Call fake.cmd, such that a restore is triggert

  4. Open directory in Ionide

repo

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:

  1. Replacing the \ with /
  2. 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:closed
  • Created 6 years ago
  • Comments:7 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
matthidcommented, Feb 28, 2018

+45 −18 is still kind of review-able 😉

0reactions
forkicommented, Feb 28, 2018

that one gets huge 😉

Read more comments on GitHub >

github_iconTop 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 >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found