Flakes: Difference between revisions

imported>Raboof
imported>SuperSamus
Add local git repo example
Line 88: Line 88:
{
{
   inputs = {
   inputs = {
     # github example, also supported gitlab:
     # GitHub example, also supports GitLab:
     nixpkgs.url = "github:Mic92/nixpkgs/master";
     nixpkgs.url = "github:Mic92/nixpkgs/master";
     # git urls
     # 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:')
     # 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";