Skip to content

flake: fix string escapes#361

Open
antonmosich wants to merge 1 commit intoserokell:masterfrom
antonmosich:escapes
Open

flake: fix string escapes#361
antonmosich wants to merge 1 commit intoserokell:masterfrom
antonmosich:escapes

Conversation

@antonmosich
Copy link

In nixlang "\." is escaped to just ".". That is, it does nothing. For there to be a "\." in the resulting string, two backslashes are needed. Lix on main now emits a warning in such cases. See the example nix repl output:

nix-repl> :p "Cargo\.lock"
Cargo.lock

nix-repl> :p "Cargo\\.lock"
Cargo\.lock

In nixlang "\." is escaped to just ".". That is, it does nothing. For
there to be a "\." in the resulting string, two backslashes are needed.
Lix on main now emits a warning in such cases. See the example nix repl
output:
	nix-repl> :p "Cargo\.lock"
	Cargo.lock

	nix-repl> :p "Cargo\\.lock"
	Cargo\.lock
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant