]> git.ipfire.org Git - thirdparty/git.git/blobdiff - builtin/show-ref.c
Merge branch 'vd/fsck-submodule-url-test'
[thirdparty/git.git] / builtin / show-ref.c
index 7aac525a878b3b3ae4959a831de4747d379e140f..aaa2c39b2f636c6a031dc98f237c83d59b754f31 100644 (file)
@@ -6,7 +6,6 @@
 #include "object-name.h"
 #include "object-store-ll.h"
 #include "object.h"
-#include "tag.h"
 #include "string-list.h"
 #include "parse-options.h"
 
@@ -315,9 +314,9 @@ int cmd_show_ref(int argc, const char **argv, const char *prefix)
        argc = parse_options(argc, argv, prefix, show_ref_options,
                             show_ref_usage, 0);
 
-       if ((!!exclude_existing_opts.enabled + !!verify + !!exists) > 1)
-               die(_("only one of '%s', '%s' or '%s' can be given"),
-                   "--exclude-existing", "--verify", "--exists");
+       die_for_incompatible_opt3(exclude_existing_opts.enabled, "--exclude-existing",
+                                 verify, "--verify",
+                                 exists, "--exists");
 
        if (exclude_existing_opts.enabled)
                return cmd_show_ref__exclude_existing(&exclude_existing_opts);