diff options
author | Eelco Dolstra <edolstra@gmail.com> | 2019-09-02 17:33:07 +0200 |
---|---|---|
committer | Eelco Dolstra <edolstra@gmail.com> | 2019-09-02 17:35:35 +0200 |
commit | 61fdb16aacf9ff18c96b72a37e1b46eb14586eb4 (patch) | |
tree | e513ef2858e96d2b9d764c5e9b5fe5b3bec2f250 /src/libexpr/flake/flakeref.hh | |
parent | 5ec2a1ed82d485429aaf6fbad55fd6c1320b2d8c (diff) |
Improve error message when a directory is not a flake
So you now get
$ nix build
error: path '.' is not a flake (because it does not reference a Git repository)
rather than
$ nix build
error: unsupported argument '.'
Diffstat (limited to 'src/libexpr/flake/flakeref.hh')
-rw-r--r-- | src/libexpr/flake/flakeref.hh | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/libexpr/flake/flakeref.hh b/src/libexpr/flake/flakeref.hh index 082dd8c26..9ddc227bb 100644 --- a/src/libexpr/flake/flakeref.hh +++ b/src/libexpr/flake/flakeref.hh @@ -187,6 +187,7 @@ struct FlakeRef std::ostream & operator << (std::ostream & str, const FlakeRef & flakeRef); MakeError(BadFlakeRef, Error); +MakeError(MissingFlake, BadFlakeRef); std::optional<FlakeRef> parseFlakeRef( const std::string & uri, bool allowRelative = false); |