Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nushell 0.94.1 breaks Windows path handling #13016

Closed
CarterLi opened this issue May 31, 2024 · 7 comments · Fixed by #13027
Closed

nushell 0.94.1 breaks Windows path handling #13016

CarterLi opened this issue May 31, 2024 · 7 comments · Fixed by #13027
Labels
🐛 bug Something isn't working paths windows A Windows specific issue
Milestone

Comments

@CarterLi
Copy link

CarterLi commented May 31, 2024

Describe the bug

Error:   × Invalid literal
     ╭─[C:\Users\zhang\AppData\Roaming\nushell\config.nu:792:17]
 791 │ #use ~/.starship.nu
 792 │ alias curl = c:\msys64\clangarm64\bin\curl.exe
     ·                 ───────────────┬──────────────
     ·                                ╰── unrecognized escape after '\' in string
 793 │ alias vim = nvim
     ╰────

How to reproduce

Windows style paths in config file result in error unrecognized escape after '\' in string

Expected behavior

Don't error

Screenshots

N/A

Configuration

N/A

Additional context

Regression in 0.94.1. It worked in 0.94.0

@CarterLi CarterLi added the needs-triage An issue that hasn't had any proper look label May 31, 2024
@YizhePKU
Copy link
Contributor

@devyn Probably a side-effect of #13001.

@Deebster
Copy link

Deebster commented May 31, 2024

You can replace each backslash with a double backslash, but it's very tedious to do this outside of scripts.

I've downgraded until it's fixed with cargo install --version 0.94.0 nu (edit: hmm, I'm now seeing the issue on 0.94.0)

@CarterLi
Copy link
Author

starship generates nu scripts with Windows style paths.

BTW starship works weird after upgrading nu to 0.94.0+

@chtenb
Copy link

chtenb commented May 31, 2024

Huh, I downgraded to 0.94.0 again, but the issue persists, as in, my config scripts that worked earlier on 0.94.0 no longer work after downgrading from 0.94.1!

@kubouch
Copy link
Contributor

kubouch commented May 31, 2024

On my Windows end, the issue appears at 0.94.1. The version 0.94.0 works fine.

@devyn devyn added 🐛 bug Something isn't working windows A Windows specific issue paths and removed needs-triage An issue that hasn't had any proper look labels Jun 1, 2024
kubouch pushed a commit that referenced this issue Jun 3, 2024
…3027)

# Description

Fixes #13016 and adds tests for many variations of external call
parsing.

I just realized @kubouch took a crack at this too (#13022) so really
whichever is better, but I think the
tests are a good addition.
@rogtino
Copy link

rogtino commented Jun 3, 2024

Hello team,would you mind posting a bug fix release?

@kubouch
Copy link
Contributor

kubouch commented Jun 3, 2024

Yes, it's coming within a day.

@hustcer hustcer added this to the v0.95.0 milestone Jun 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Something isn't working paths windows A Windows specific issue
Projects
None yet
8 participants