packaging: Add contrib installation
[platform/upstream/git.git] / wt-status.h
index 73ab5d4..0d32799 100644 (file)
@@ -77,8 +77,7 @@ enum wt_status_format {
        STATUS_FORMAT_UNSPECIFIED
 };
 
-#define HEAD_DETACHED_AT _("HEAD detached at ")
-#define HEAD_DETACHED_FROM _("HEAD detached from ")
+#define SPARSE_CHECKOUT_DISABLED -1
 
 struct wt_status_state {
        int merge_in_progress;
@@ -90,6 +89,7 @@ struct wt_status_state {
        int bisect_in_progress;
        int revert_in_progress;
        int detached_at;
+       int sparse_checkout_percentage; /* SPARSE_CHECKOUT_DISABLED if not sparse */
        char *branch;
        char *onto;
        char *detached_from;
@@ -149,7 +149,14 @@ void wt_status_add_cut_line(FILE *fp);
 void wt_status_prepare(struct repository *r, struct wt_status *s);
 void wt_status_print(struct wt_status *s);
 void wt_status_collect(struct wt_status *s);
+/*
+ * Frees the buffers allocated by wt_status_collect.
+ */
 void wt_status_collect_free_buffers(struct wt_status *s);
+/*
+ * Frees the buffers of the wt_status_state.
+ */
+void wt_status_state_free_buffers(struct wt_status_state *s);
 void wt_status_get_state(struct repository *repo,
                         struct wt_status_state *state,
                         int get_detached_from);