mirror of
https://github.com/NixOS/nix
synced 2025-06-25 10:41:16 +02:00
allow ^ in URLs
Users may select specific outputs using the ^output syntax or selecting any output using ^*. URL parsing currently doesn't support these kinds of output references: parsing will fail. Currently `queryRegex` was reused for URL fragments, which didn't include support for ^. Now queryRegex has been split from fragmentRegex, where only the fragmentRegex supports ^.
This commit is contained in:
parent
257b768436
commit
9c0a09f09f
6 changed files with 10 additions and 4 deletions
|
@ -15,7 +15,7 @@ ParsedURL parseURL(const std::string & url)
|
|||
"((" + schemeRegex + "):"
|
||||
+ "(?:(?://(" + authorityRegex + ")(" + absPathRegex + "))|(/?" + pathRegex + ")))"
|
||||
+ "(?:\\?(" + queryRegex + "))?"
|
||||
+ "(?:#(" + queryRegex + "))?",
|
||||
+ "(?:#(" + fragmentRegex + "))?",
|
||||
std::regex::ECMAScript);
|
||||
|
||||
std::smatch match;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue