Commit 36558513c8d9c70cc920e7f2b19e69c11a5946ac

Edward Thomson 2019-06-24T23:31:23

configuration: deprecate git_cvar safely

diff --git a/include/git2/deprecated.h b/include/git2/deprecated.h
index 912396f..fec56b1 100644
--- a/include/git2/deprecated.h
+++ b/include/git2/deprecated.h
@@ -7,6 +7,7 @@
 #ifndef INCLUDE_git_deprecated_h__
 #define INCLUDE_git_deprecated_h__
 
+#include "config.h"
 #include "common.h"
 #include "blame.h"
 #include "buffer.h"
@@ -116,6 +117,19 @@ GIT_EXTERN(void) git_buf_free(git_buf *buffer);
 
 /**@}*/
 
+/** @name Deprecated Config Functions and Constants
+ */
+/**@{*/
+
+#define GIT_CVAR_FALSE  GIT_CONFIGMAP_FALSE
+#define GIT_CVAR_TRUE   GIT_CONFIGMAP_TRUE
+#define GIT_CVAR_INT32  GIT_CONFIGMAP_INT32
+#define GIT_CVAR_STRING GIT_CONFIGMAP_STRING
+
+typedef git_configmap git_cvar_map;
+
+/**@}*/
+
 /** @name Deprecated Error Functions and Constants
  *
  * These functions and enumeration values are retained for backward