@@ -160,7 +160,7 @@ static void wt_status_print_unmerged_header(struct wt_status *s)
160
160
}
161
161
}
162
162
163
- if (!advice_status_hints )
163
+ if (!s -> hints )
164
164
return ;
165
165
if (s -> whence != FROM_COMMIT )
166
166
;
@@ -187,7 +187,7 @@ static void wt_status_print_cached_header(struct wt_status *s)
187
187
const char * c = color (WT_STATUS_HEADER , s );
188
188
189
189
status_printf_ln (s , c , _ ("Changes to be committed:" ));
190
- if (!advice_status_hints )
190
+ if (!s -> hints )
191
191
return ;
192
192
if (s -> whence != FROM_COMMIT )
193
193
; /* NEEDSWORK: use "git reset --unresolve"??? */
@@ -205,7 +205,7 @@ static void wt_status_print_dirty_header(struct wt_status *s,
205
205
const char * c = color (WT_STATUS_HEADER , s );
206
206
207
207
status_printf_ln (s , c , _ ("Changes not staged for commit:" ));
208
- if (!advice_status_hints )
208
+ if (!s -> hints )
209
209
return ;
210
210
if (!has_deleted )
211
211
status_printf_ln (s , c , _ (" (use \"git add <file>...\" to update what will be committed)" ));
@@ -223,7 +223,7 @@ static void wt_status_print_other_header(struct wt_status *s,
223
223
{
224
224
const char * c = color (WT_STATUS_HEADER , s );
225
225
status_printf_ln (s , c , "%s:" , what );
226
- if (!advice_status_hints )
226
+ if (!s -> hints )
227
227
return ;
228
228
status_printf_ln (s , c , _ (" (use \"git %s <file>...\" to include in what will be committed)" ), how );
229
229
status_printf_ln (s , c , "" );
@@ -801,13 +801,13 @@ static void show_merge_in_progress(struct wt_status *s,
801
801
{
802
802
if (has_unmerged (s )) {
803
803
status_printf_ln (s , color , _ ("You have unmerged paths." ));
804
- if (advice_status_hints )
804
+ if (s -> hints )
805
805
status_printf_ln (s , color ,
806
806
_ (" (fix conflicts and run \"git commit\")" ));
807
807
} else {
808
808
status_printf_ln (s , color ,
809
809
_ ("All conflicts fixed but you are still merging." ));
810
- if (advice_status_hints )
810
+ if (s -> hints )
811
811
status_printf_ln (s , color ,
812
812
_ (" (use \"git commit\" to conclude merge)" ));
813
813
}
@@ -823,7 +823,7 @@ static void show_am_in_progress(struct wt_status *s,
823
823
if (state -> am_empty_patch )
824
824
status_printf_ln (s , color ,
825
825
_ ("The current patch is empty." ));
826
- if (advice_status_hints ) {
826
+ if (s -> hints ) {
827
827
if (!state -> am_empty_patch )
828
828
status_printf_ln (s , color ,
829
829
_ (" (fix conflicts and then run \"git am --continue\")" ));
@@ -896,7 +896,7 @@ static void show_rebase_in_progress(struct wt_status *s,
896
896
else
897
897
status_printf_ln (s , color ,
898
898
_ ("You are currently rebasing." ));
899
- if (advice_status_hints ) {
899
+ if (s -> hints ) {
900
900
status_printf_ln (s , color ,
901
901
_ (" (fix conflicts and then run \"git rebase --continue\")" ));
902
902
status_printf_ln (s , color ,
@@ -913,7 +913,7 @@ static void show_rebase_in_progress(struct wt_status *s,
913
913
else
914
914
status_printf_ln (s , color ,
915
915
_ ("You are currently rebasing." ));
916
- if (advice_status_hints )
916
+ if (s -> hints )
917
917
status_printf_ln (s , color ,
918
918
_ (" (all conflicts fixed: run \"git rebase --continue\")" ));
919
919
} else if (split_commit_in_progress (s )) {
@@ -925,7 +925,7 @@ static void show_rebase_in_progress(struct wt_status *s,
925
925
else
926
926
status_printf_ln (s , color ,
927
927
_ ("You are currently splitting a commit during a rebase." ));
928
- if (advice_status_hints )
928
+ if (s -> hints )
929
929
status_printf_ln (s , color ,
930
930
_ (" (Once your working directory is clean, run \"git rebase --continue\")" ));
931
931
} else {
@@ -937,7 +937,7 @@ static void show_rebase_in_progress(struct wt_status *s,
937
937
else
938
938
status_printf_ln (s , color ,
939
939
_ ("You are currently editing a commit during a rebase." ));
940
- if (advice_status_hints && !s -> amend ) {
940
+ if (s -> hints && !s -> amend ) {
941
941
status_printf_ln (s , color ,
942
942
_ (" (use \"git commit --amend\" to amend the current commit)" ));
943
943
status_printf_ln (s , color ,
@@ -952,7 +952,7 @@ static void show_cherry_pick_in_progress(struct wt_status *s,
952
952
const char * color )
953
953
{
954
954
status_printf_ln (s , color , _ ("You are currently cherry-picking." ));
955
- if (advice_status_hints ) {
955
+ if (s -> hints ) {
956
956
if (has_unmerged (s ))
957
957
status_printf_ln (s , color ,
958
958
_ (" (fix conflicts and run \"git cherry-pick --continue\")" ));
@@ -971,7 +971,7 @@ static void show_revert_in_progress(struct wt_status *s,
971
971
{
972
972
status_printf_ln (s , color , _ ("You are currently reverting commit %s." ),
973
973
find_unique_abbrev (state -> revert_head_sha1 , DEFAULT_ABBREV ));
974
- if (advice_status_hints ) {
974
+ if (s -> hints ) {
975
975
if (has_unmerged (s ))
976
976
status_printf_ln (s , color ,
977
977
_ (" (fix conflicts and run \"git revert --continue\")" ));
@@ -995,7 +995,7 @@ static void show_bisect_in_progress(struct wt_status *s,
995
995
else
996
996
status_printf_ln (s , color ,
997
997
_ ("You are currently bisecting." ));
998
- if (advice_status_hints )
998
+ if (s -> hints )
999
999
status_printf_ln (s , color ,
1000
1000
_ (" (use \"git bisect reset\" to get back to the original branch)" ));
1001
1001
wt_status_print_trailer (s );
@@ -1233,7 +1233,7 @@ void wt_status_print(struct wt_status *s)
1233
1233
}
1234
1234
} else if (s -> commitable )
1235
1235
status_printf_ln (s , GIT_COLOR_NORMAL , _ ("Untracked files not listed%s" ),
1236
- advice_status_hints
1236
+ s -> hints
1237
1237
? _ (" (use -u option to show untracked files)" ) : "" );
1238
1238
1239
1239
if (s -> verbose )
@@ -1244,25 +1244,25 @@ void wt_status_print(struct wt_status *s)
1244
1244
else if (s -> nowarn )
1245
1245
; /* nothing */
1246
1246
else if (s -> workdir_dirty ) {
1247
- if (advice_status_hints )
1247
+ if (s -> hints )
1248
1248
printf (_ ("no changes added to commit "
1249
1249
"(use \"git add\" and/or \"git commit -a\")\n" ));
1250
1250
else
1251
1251
printf (_ ("no changes added to commit\n" ));
1252
1252
} else if (s -> untracked .nr ) {
1253
- if (advice_status_hints )
1253
+ if (s -> hints )
1254
1254
printf (_ ("nothing added to commit but untracked files "
1255
1255
"present (use \"git add\" to track)\n" ));
1256
1256
else
1257
1257
printf (_ ("nothing added to commit but untracked files present\n" ));
1258
1258
} else if (s -> is_initial ) {
1259
- if (advice_status_hints )
1259
+ if (s -> hints )
1260
1260
printf (_ ("nothing to commit (create/copy files "
1261
1261
"and use \"git add\" to track)\n" ));
1262
1262
else
1263
1263
printf (_ ("nothing to commit\n" ));
1264
1264
} else if (!s -> show_untracked_files ) {
1265
- if (advice_status_hints )
1265
+ if (s -> hints )
1266
1266
printf (_ ("nothing to commit (use -u to show untracked files)\n" ));
1267
1267
else
1268
1268
printf (_ ("nothing to commit\n" ));
0 commit comments