Commit 0f729f21 authored by Kristian Høgsberg's avatar Kristian Høgsberg Committed by Junio C Hamano

Enable wt-status to run against non-standard index file.

We still default to get_index_file(), but this can be overridden
by setting wt_status.index_file after calling wt_status_prepare().
Signed-off-by: default avatarKristian Høgsberg <[email protected]>
Signed-off-by: default avatarJunio C Hamano <[email protected]>
parent f26a0012
......@@ -53,6 +53,7 @@ void wt_status_prepare(struct wt_status *s)
s->branch = head ? xstrdup(head) : NULL;
s->reference = "HEAD";
s->fp = stdout;
s->index_file = get_index_file();
static void wt_status_print_cached_header(struct wt_status *s)
......@@ -198,7 +199,7 @@ static void wt_status_print_changed_cb(struct diff_queue_struct *q,
static void wt_read_cache(struct wt_status *s)
static void wt_status_print_initial(struct wt_status *s)
......@@ -21,6 +21,7 @@ struct wt_status {
int commitable;
int workdir_dirty;
int workdir_untracked;
const char *index_file;
FILE *fp;
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment