Flakes: Difference between revisions
imported>Raboof m →Using flakes project from a legacy Nix: formatting |
imported>SuperSamus Add local git repo example |
||
| Line 88: | Line 88: | ||
{ | { | ||
inputs = { | inputs = { | ||
# | # GitHub example, also supports GitLab: | ||
nixpkgs.url = "github:Mic92/nixpkgs/master"; | nixpkgs.url = "github:Mic92/nixpkgs/master"; | ||
# | # Git urls | ||
git-example.url = "git+https://git.somehost.tld/user/path?ref=branch&rev=fdc8ef970de2b4634e1b3dca296e1ed918459a9e"; | git-example.url = "git+https://git.somehost.tld/user/path?ref=branch&rev=fdc8ef970de2b4634e1b3dca296e1ed918459a9e"; | ||
# | # Local directories (for absolute paths you can omit 'path:') | ||
directory-example.url = "path:/path/to/repo"; | directory-example.url = "path:/path/to/repo"; | ||
# The above url will also copy .git, use this for (shallow) local Git repos | |||
git-directory-example.url = "git+path:/path/to/repo?shallow=true" | |||
# Use this for non-flakes | # Use this for non-flakes | ||
bar.url = "github:foo/bar/branch"; | bar.url = "github:foo/bar/branch"; | ||