summaryrefslogtreecommitdiff
path: root/builtin-check-ref-format.c
diff options
context:
space:
mode:
authorLukas Sandström <lukass@etek.chalmers.se>2006-05-18 12:15:55 (GMT)
committerJunio C Hamano <junkio@cox.net>2006-05-18 22:51:38 (GMT)
commit9370bae2cef351617272aa142fbe4ce039833d13 (patch)
tree7265a2b5e3fbcdee3a5c45b0b4469016ad5891d6 /builtin-check-ref-format.c
parent5fb61b8dcfdf7bcec0793c071813e255d1803859 (diff)
downloadgit-9370bae2cef351617272aa142fbe4ce039833d13.zip
git-9370bae2cef351617272aa142fbe4ce039833d13.tar.gz
git-9370bae2cef351617272aa142fbe4ce039833d13.tar.bz2
Make git-check-format-ref a builtin.
Signed-off-by: Lukas Sandström <lukass@etek.chalmers.se> Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'builtin-check-ref-format.c')
-rw-r--r--builtin-check-ref-format.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/builtin-check-ref-format.c b/builtin-check-ref-format.c
new file mode 100644
index 0000000..4a23936
--- /dev/null
+++ b/builtin-check-ref-format.c
@@ -0,0 +1,14 @@
+/*
+ * GIT - The information manager from hell
+ */
+
+#include "cache.h"
+#include "refs.h"
+#include "builtin.h"
+
+int cmd_check_ref_format(int argc, const char **argv, char **envp)
+{
+ if (argc != 2)
+ usage("git check-ref-format refname");
+ return !!check_ref_format(argv[1]);
+}