File tree 2 files changed +30
-0
lines changed
2 files changed +30
-0
lines changed Original file line number Diff line number Diff line change @@ -107,6 +107,7 @@ fn main() {
107
107
features. push_str ( "#ifndef INCLUDE_features_h\n " ) ;
108
108
features. push_str ( "#define INCLUDE_features_h\n " ) ;
109
109
features. push_str ( "#define GIT_THREADS 1\n " ) ;
110
+ features. push_str ( "#define GIT_TRACE 1\n " ) ;
110
111
111
112
if !target. contains ( "android" ) {
112
113
features. push_str ( "#define GIT_USE_NSEC 1\n " ) ;
Original file line number Diff line number Diff line change @@ -1892,6 +1892,33 @@ pub const GIT_WORKTREE_PRUNE_OPTIONS_VERSION: c_uint = 1;
1892
1892
pub type git_repository_mergehead_foreach_cb =
1893
1893
Option < extern "C" fn ( oid : * const git_oid , payload : * mut c_void ) -> c_int > ;
1894
1894
1895
+ git_enum ! {
1896
+ pub enum git_trace_level_t {
1897
+ /* No tracing will be performed. */
1898
+ GIT_TRACE_NONE = 0 ,
1899
+
1900
+ /* Severe errors that may impact the program's execution */
1901
+ GIT_TRACE_FATAL = 1 ,
1902
+
1903
+ /* Errors that do not impact the program's execution */
1904
+ GIT_TRACE_ERROR = 2 ,
1905
+
1906
+ /* Warnings that suggest abnormal data */
1907
+ GIT_TRACE_WARN = 3 ,
1908
+
1909
+ /* Informational messages about program execution */
1910
+ GIT_TRACE_INFO = 4 ,
1911
+
1912
+ /* Detailed data that allows for debugging */
1913
+ GIT_TRACE_DEBUG = 5 ,
1914
+
1915
+ /* Exceptionally detailed debugging data */
1916
+ GIT_TRACE_TRACE = 6 ,
1917
+ }
1918
+ }
1919
+
1920
+ pub type git_trace_cb = Option < extern "C" fn ( level : git_trace_level_t , msg : * const c_char ) > ;
1921
+
1895
1922
extern "C" {
1896
1923
// threads
1897
1924
pub fn git_libgit2_init ( ) -> c_int ;
@@ -3986,6 +4013,8 @@ extern "C" {
3986
4013
replace_name : * const c_char ,
3987
4014
replace_email : * const c_char ,
3988
4015
) -> c_int ;
4016
+
4017
+ pub fn git_trace_set ( level : git_trace_level_t , cb : git_trace_cb ) -> c_int ;
3989
4018
}
3990
4019
3991
4020
pub fn init ( ) {
You can’t perform that action at this time.
0 commit comments