File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change 35
35
#define ONTO_FILE "onto"
36
36
#define ONTO_NAME_FILE "onto_name"
37
37
#define QUIET_FILE "quiet"
38
+ #define INTERACTIVE_FILE "interactive"
38
39
39
40
#define MSGNUM_FILE "msgnum"
40
41
#define END_FILE "end"
@@ -92,6 +93,7 @@ static int rebase_state_type(
92
93
git_repository * repo )
93
94
{
94
95
git_str path = GIT_STR_INIT ;
96
+ git_str interactive_path = GIT_STR_INIT ;
95
97
git_rebase_t type = GIT_REBASE_NONE ;
96
98
97
99
if (git_str_joinpath (& path , repo -> gitdir , REBASE_APPLY_DIR ) < 0 )
@@ -107,7 +109,14 @@ static int rebase_state_type(
107
109
return -1 ;
108
110
109
111
if (git_fs_path_isdir (git_str_cstr (& path ))) {
110
- type = GIT_REBASE_MERGE ;
112
+ if (git_str_joinpath (& interactive_path , path .ptr , INTERACTIVE_FILE ) < 0 )
113
+ return -1 ;
114
+
115
+ if (git_fs_path_isfile (interactive_path .ptr ))
116
+ type = GIT_REBASE_INTERACTIVE ;
117
+ else
118
+ type = GIT_REBASE_MERGE ;
119
+
111
120
goto done ;
112
121
}
113
122
@@ -118,6 +127,7 @@ static int rebase_state_type(
118
127
* path_out = git_str_detach (& path );
119
128
120
129
git_str_dispose (& path );
130
+ git_str_dispose (& interactive_path );
121
131
122
132
return 0 ;
123
133
}
You can’t perform that action at this time.
0 commit comments