summaryrefslogtreecommitdiff
path: root/common-main.c
diff options
context:
space:
mode:
Diffstat (limited to 'common-main.c')
-rw-r--r--common-main.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/common-main.c b/common-main.c
new file mode 100644
index 0000000000..6b7ab077b0
--- /dev/null
+++ b/common-main.c
@@ -0,0 +1,13 @@
+#include "git-compat-util.h"
+#include "common-init.h"
+
+int main(int argc, const char **argv)
+{
+ int result;
+
+ init_git(argv);
+ result = cmd_main(argc, argv);
+
+ /* Not exit(3), but a wrapper calling our common_exit() */
+ exit(result);
+}