1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-06 21:41:48 +02:00

ParsedURL: Remove url field

This prevents a 'url' field that is out of sync with the other
fields. You can use to_string() to get the full URL.

(cherry picked from commit f705ce7f9a)
This commit is contained in:
Eelco Dolstra 2025-01-07 14:45:58 +01:00
parent aa5246bfe3
commit 8856b5f2ca
8 changed files with 25 additions and 43 deletions

View file

@ -161,7 +161,6 @@ std::pair<FlakeRef, std::string> parsePathFlakeRefWithFragment(
auto base = std::string("git+file://") + flakeRoot;
auto parsedURL = ParsedURL{
.url = base, // FIXME
.base = base,
.scheme = "git+file",
.authority = "",
@ -219,7 +218,6 @@ static std::optional<std::pair<FlakeRef, std::string>> parseFlakeIdRef(
if (std::regex_match(url, match, flakeRegex)) {
auto parsedURL = ParsedURL{
.url = url,
.base = "flake:" + match.str(1),
.scheme = "flake",
.authority = "",