From 1e7be10de0d493f471bf102a7eed32da8247c825 Mon Sep 17 00:00:00 2001 From: Jeff Hostetler Date: Thu, 26 May 2022 21:47:02 +0000 Subject: fsmonitor-settings: remote repos on macOS are incompatible Teach Git to detect remote working directories on macOS and mark them as incompatible with FSMonitor. With this, `git fsmonitor--daemon run` will error out with a message like it does for bare repos. Client commands, like `git status`, will not attempt to start the daemon. Signed-off-by: Jeff Hostetler Signed-off-by: Junio C Hamano --- fsmonitor-settings.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'fsmonitor-settings.c') diff --git a/fsmonitor-settings.c b/fsmonitor-settings.c index 600ae165ab..d2fb0141f8 100644 --- a/fsmonitor-settings.c +++ b/fsmonitor-settings.c @@ -208,6 +208,18 @@ char *fsm_settings__get_incompatible_msg(const struct repository *r, xgetcwd()); goto done; + case FSMONITOR_REASON_ERROR: + strbuf_addf(&msg, + _("repository '%s' is incompatible with fsmonitor due to errors"), + r->worktree); + goto done; + + case FSMONITOR_REASON_REMOTE: + strbuf_addf(&msg, + _("remote repository '%s' is incompatible with fsmonitor"), + r->worktree); + goto done; + case FSMONITOR_REASON_VFS4GIT: strbuf_addf(&msg, _("virtual repository '%s' is incompatible with fsmonitor"), -- cgit v1.2.3