--- /dev/null
+/*
+ * Copyright © 2012, Titanium Mirror, Inc.
+ * All Rights Reserved.
+ *
+ * This document is the proprietary and confidential property of
+ * Titanium Mirror, Inc. All use, distribution, reproduction or re-distribution
+ * is disallowed without the prior express written consent of
+ * Titanium Mirror, Inc.
+ */
+
+/*
+ * Test parsing of the git acl config file
+ *
+ * @author R. Steve McKown <rsmckown@gmail.com>
+ */
+
+#include <stdio.h>
+#include "git_acl.h"
+
+int main(int argc, char **argv)
+{
+ char *file = "git_acl.cfg.example";
+ perms_t p;
+
+ if (argc != 3)
+ die("usage: %s <username> <reponame>\n", argv[0]);
+
+ p = git_acl(argv[1], argv[2], file); /* file=NULL for default */
+
+ printf("config file %s\n"
+ "GITACL(%s@%s) = %s(%u)\n via repoid='%s', userid='%s'\n",
+ file, argv[1], argv[2], git_acl_perms_as_str(p), p,
+ git_acl_last_repoid(), git_acl_last_userid());
+ return 0;
+}