make struct got_repository opaque
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44
diff --git a/include/got_repository.h b/include/got_repository.h
index 49c27b1..3ca9626 100644
--- a/include/got_repository.h
+++ b/include/got_repository.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017 Stefan Sperling <stsp@openbsd.org>
+ * Copyright (c) 2018 Stefan Sperling <stsp@openbsd.org>
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -14,9 +14,7 @@
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
-struct got_repository {
- char *path;
-};
+struct got_repository;
/* Open and close git repositories. */
const struct got_error *got_repo_open(struct got_repository**, const char *);
diff --git a/lib/repository.c b/lib/repository.c
index 3542514..d6d9843 100644
--- a/lib/repository.c
+++ b/lib/repository.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2017 Stefan Sperling <stsp@openbsd.org>
+ * Copyright (c) 2018 Stefan Sperling <stsp@openbsd.org>
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -26,6 +26,10 @@
#include "path.h"
+struct got_repository {
+ char *path;
+};
+
#define GOT_GIT_DIR ".git"
/* Mandatory files and directories inside the git directory. */