#define USE_THE_REPOSITORY_VARIABLE
#include "git-compat-util.h"
#include "advice.h"
#include "wt-status.h"
#include "object.h"
#include "dir.h"
#include "commit.h"
#include "diff.h"
#include "environment.h"
#include "gettext.h"
#include "hash.h"
#include "hex.h"
#include "object-name.h"
#include "path.h"
#include "revision.h"
#include "diffcore.h"
#include "quote.h"
#include "repository.h"
#include "run-command.h"
#include "strvec.h"
#include "remote.h"
#include "refs.h"
#include "submodule.h"
#include "column.h"
#include "read-cache.h"
#include "setup.h"
#include "strbuf.h"
#include "trace.h"
#include "trace2.h"
#include "tree.h"
#include "utf8.h"
#include "worktree.h"
#include "lockfile.h"
#include "sequencer.h"
#include "fsmonitor-settings.h"
#define AB_DELAY_WARNING_IN_MS …
#define UF_DELAY_WARNING_IN_MS …
static const char cut_line[] = …;
static char default_wt_status_colors[][COLOR_MAXLEN] = …;
static const char *color(int slot, struct wt_status *s)
{ … }
static void status_vprintf(struct wt_status *s, int at_bol, const char *color,
const char *fmt, va_list ap, const char *trail)
{ … }
void status_printf_ln(struct wt_status *s, const char *color,
const char *fmt, ...)
{ … }
void status_printf(struct wt_status *s, const char *color,
const char *fmt, ...)
{ … }
__attribute__((format (printf, 3, 4)))
static void status_printf_more(struct wt_status *s, const char *color,
const char *fmt, ...)
{ … }
void wt_status_prepare(struct repository *r, struct wt_status *s)
{ … }
static void wt_longstatus_print_unmerged_header(struct wt_status *s)
{ … }
static void wt_longstatus_print_cached_header(struct wt_status *s)
{ … }
static void wt_longstatus_print_dirty_header(struct wt_status *s,
int has_deleted,
int has_dirty_submodules)
{ … }
static void wt_longstatus_print_other_header(struct wt_status *s,
const char *what,
const char *how)
{ … }
static void wt_longstatus_print_trailer(struct wt_status *s)
{ … }
static const char *wt_status_unmerged_status_string(int stagemask)
{ … }
static const char *wt_status_diff_status_string(int status)
{ … }
static int maxwidth(const char *(*label)(int), int minval, int maxval)
{ … }
static void wt_longstatus_print_unmerged_data(struct wt_status *s,
struct string_list_item *it)
{ … }
static void wt_longstatus_print_change_data(struct wt_status *s,
int change_type,
struct string_list_item *it)
{ … }
static char short_submodule_status(struct wt_status_change_data *d)
{ … }
static void wt_status_collect_changed_cb(struct diff_queue_struct *q,
struct diff_options *options UNUSED,
void *data)
{ … }
static int unmerged_mask(struct index_state *istate, const char *path)
{ … }
static void wt_status_collect_updated_cb(struct diff_queue_struct *q,
struct diff_options *options UNUSED,
void *data)
{ … }
static void wt_status_collect_changes_worktree(struct wt_status *s)
{ … }
static void wt_status_collect_changes_index(struct wt_status *s)
{ … }
static int add_file_to_list(const struct object_id *oid,
struct strbuf *base, const char *path,
unsigned int mode, void *context)
{ … }
static void wt_status_collect_changes_initial(struct wt_status *s)
{ … }
static void wt_status_collect_untracked(struct wt_status *s)
{ … }
static int has_unmerged(struct wt_status *s)
{ … }
void wt_status_collect(struct wt_status *s)
{ … }
void wt_status_collect_free_buffers(struct wt_status *s)
{ … }
void wt_status_state_free_buffers(struct wt_status_state *state)
{ … }
static void wt_longstatus_print_unmerged(struct wt_status *s)
{ … }
static void wt_longstatus_print_updated(struct wt_status *s)
{ … }
static int wt_status_check_worktree_changes(struct wt_status *s,
int *dirty_submodules)
{ … }
static void wt_longstatus_print_changed(struct wt_status *s)
{ … }
static int stash_count_refs(struct object_id *ooid UNUSED,
struct object_id *noid UNUSED,
const char *email UNUSED,
timestamp_t timestamp UNUSED, int tz UNUSED,
const char *message UNUSED, void *cb_data)
{ … }
static int count_stash_entries(void)
{ … }
static void wt_longstatus_print_stash_summary(struct wt_status *s)
{ … }
static void wt_longstatus_print_submodule_summary(struct wt_status *s, int uncommitted)
{ … }
static void wt_longstatus_print_other(struct wt_status *s,
struct string_list *l,
const char *what,
const char *how)
{ … }
size_t wt_status_locate_end(const char *s, size_t len)
{ … }
void wt_status_append_cut_line(struct strbuf *buf)
{ … }
void wt_status_add_cut_line(struct wt_status *s)
{ … }
static void wt_longstatus_print_verbose(struct wt_status *s)
{ … }
static void wt_longstatus_print_tracking(struct wt_status *s)
{ … }
static int uf_was_slow(struct wt_status *s)
{ … }
static void show_merge_in_progress(struct wt_status *s,
const char *color)
{ … }
static void show_am_in_progress(struct wt_status *s,
const char *color)
{ … }
static char *read_line_from_git_path(const char *filename)
{ … }
static int split_commit_in_progress(struct wt_status *s)
{ … }
static void abbrev_oid_in_line(struct strbuf *line)
{ … }
static int read_rebase_todolist(const char *fname, struct string_list *lines)
{ … }
static void show_rebase_information(struct wt_status *s,
const char *color)
{ … }
static void print_rebase_state(struct wt_status *s,
const char *color)
{ … }
static void show_rebase_in_progress(struct wt_status *s,
const char *color)
{ … }
static void show_cherry_pick_in_progress(struct wt_status *s,
const char *color)
{ … }
static void show_revert_in_progress(struct wt_status *s,
const char *color)
{ … }
static void show_bisect_in_progress(struct wt_status *s,
const char *color)
{ … }
static void show_sparse_checkout_in_use(struct wt_status *s,
const char *color)
{ … }
static char *get_branch(const struct worktree *wt, const char *path)
{ … }
struct grab_1st_switch_cbdata { … };
static int grab_1st_switch(struct object_id *ooid UNUSED,
struct object_id *noid,
const char *email UNUSED,
timestamp_t timestamp UNUSED, int tz UNUSED,
const char *message, void *cb_data)
{ … }
static void wt_status_get_detached_from(struct repository *r,
struct wt_status_state *state)
{ … }
int wt_status_check_rebase(const struct worktree *wt,
struct wt_status_state *state)
{ … }
int wt_status_check_bisect(const struct worktree *wt,
struct wt_status_state *state)
{ … }
static void wt_status_check_sparse_checkout(struct repository *r,
struct wt_status_state *state)
{ … }
void wt_status_get_state(struct repository *r,
struct wt_status_state *state,
int get_detached_from)
{ … }
static void wt_longstatus_print_state(struct wt_status *s)
{ … }
static void wt_longstatus_print(struct wt_status *s)
{ … }
static void wt_shortstatus_unmerged(struct string_list_item *it,
struct wt_status *s)
{ … }
static void wt_shortstatus_status(struct string_list_item *it,
struct wt_status *s)
{ … }
static void wt_shortstatus_other(struct string_list_item *it,
struct wt_status *s, const char *sign)
{ … }
static void wt_shortstatus_print_tracking(struct wt_status *s)
{ … }
static void wt_shortstatus_print(struct wt_status *s)
{ … }
static void wt_porcelain_print(struct wt_status *s)
{ … }
static void wt_porcelain_v2_print_tracking(struct wt_status *s)
{ … }
static void wt_porcelain_v2_print_stash(struct wt_status *s)
{ … }
static void wt_porcelain_v2_submodule_state(
struct wt_status_change_data *d,
char sub[5])
{ … }
static void wt_porcelain_v2_fix_up_changed(struct string_list_item *it)
{ … }
static void wt_porcelain_v2_print_changed_entry(
struct string_list_item *it,
struct wt_status *s)
{ … }
static void wt_porcelain_v2_print_unmerged_entry(
struct string_list_item *it,
struct wt_status *s)
{ … }
static void wt_porcelain_v2_print_other(
struct string_list_item *it,
struct wt_status *s,
char prefix)
{ … }
static void wt_porcelain_v2_print(struct wt_status *s)
{ … }
void wt_status_print(struct wt_status *s)
{ … }
int has_unstaged_changes(struct repository *r, int ignore_submodules)
{ … }
int has_uncommitted_changes(struct repository *r,
int ignore_submodules)
{ … }
int require_clean_work_tree(struct repository *r,
const char *action,
const char *hint,
int ignore_submodules,
int gently)
{ … }