I’d like to build something from a previous commit in a local git repository, so I tried:
$ nix build "git://.?ref=master&rev=569f776585291bd3a06de95ac8c925131258d7e0#sapera_xtium"
fatal: aucun chemin spécifié ; référez-vous à 'git help pull' pour une syntaxe d'URL valide
error: program 'git' failed with exit code 128
(use '--show-trace' to show detailed location information)
and many other variations (including files/git+files…), but I can’t make it work.
As I understand it, URIs and URLs actually have identical parsing, but a URL has a standard for how to access the resource, and URIs do not.
Since only nix understands how to find the resources, and they aren’t accessed by the means that would be used for URLs, I think it’s correct to call them URIs but not URLs.
It’s also possible that you can technically only call them URI-like or URL-like, if the definition of URI requires conforming to standard structure and interpretation of existing schemes, which nix flake “URLs” do not.
For what it’s worth, the nix manual only describes them as “a URL-like syntax”, which is the most defensible approach.
urn:isbn:978-3-608-50474-3 though identifies the very same book, without telling were to find anything about it. URNs never carry a location data.
Both, URNs and URLs are URIs.
Seeing URI as the “base class” and URL beeing an “child class” inheritting some stuff is the most common definition I have seen so far, and also was what was taught at my UNI.