Re: [RFC v1] Add virtual file system settings and hook proc

2018-11-05 Thread Johannes Schindelin
Hi Ævar, On Mon, 5 Nov 2018, Ævar Arnfjörð Bjarmason wrote: > The only potential downside I see is that there's currently exactly one > implementation of this sort of thing in the wild, so we risk any such > API becoming too tied up with just what GVFS wants, and not what we'd > like to support w

Re: [RFC v1] Add virtual file system settings and hook proc

2018-11-05 Thread Ben Peart
On 11/4/2018 4:01 PM, brian m. carlson wrote: On Sun, Nov 04, 2018 at 07:34:01AM +0100, Duy Nguyen wrote: On Wed, Oct 31, 2018 at 9:53 PM Ben Peart wrote: It's more than a dynamic sparse-checkout because the same list is also used to exclude any file/folder not listed. That means any file

Re: [RFC v1] Add virtual file system settings and hook proc

2018-11-05 Thread Ben Peart
On 11/5/2018 10:22 AM, Duy Nguyen wrote: On Sun, Nov 4, 2018 at 10:01 PM brian m. carlson wrote: On Sun, Nov 04, 2018 at 07:34:01AM +0100, Duy Nguyen wrote: On Wed, Oct 31, 2018 at 9:53 PM Ben Peart wrote: It's more than a dynamic sparse-checkout because the same list is also used to exc

Re: [RFC v1] Add virtual file system settings and hook proc

2018-11-05 Thread Ben Peart
On 11/5/2018 10:26 AM, Duy Nguyen wrote: On Mon, Nov 5, 2018 at 12:40 PM Ævar Arnfjörð Bjarmason wrote: On Sun, Nov 04 2018, Duy Nguyen wrote: On Wed, Oct 31, 2018 at 9:53 PM Ben Peart wrote: +core.virtualFilesystem:: + If set, the value of this variable is used as a command whic

Re: [RFC v1] Add virtual file system settings and hook proc

2018-11-05 Thread Ben Peart
On 11/4/2018 7:02 PM, Junio C Hamano wrote: Ben Peart writes: + if (*dtype == DT_UNKNOWN) + *dtype = get_dtype(NULL, istate, pathname, pathlen); We try to defer paying cost to determine unknown *dtype as late as possible by having this call in last_exclude_matching_fro

Re: [RFC v1] Add virtual file system settings and hook proc

2018-11-05 Thread Duy Nguyen
On Mon, Nov 5, 2018 at 12:40 PM Ævar Arnfjörð Bjarmason wrote: > > > On Sun, Nov 04 2018, Duy Nguyen wrote: > > > On Wed, Oct 31, 2018 at 9:53 PM Ben Peart wrote: > >> >> +core.virtualFilesystem:: > >> >> + If set, the value of this variable is used as a command which > >> >> + will i

Re: [RFC v1] Add virtual file system settings and hook proc

2018-11-05 Thread Duy Nguyen
On Sun, Nov 4, 2018 at 10:01 PM brian m. carlson wrote: > > On Sun, Nov 04, 2018 at 07:34:01AM +0100, Duy Nguyen wrote: > > On Wed, Oct 31, 2018 at 9:53 PM Ben Peart wrote: > > > It's more than a dynamic sparse-checkout because the same list is also > > > used to exclude any file/folder not liste

Re: [RFC v1] Add virtual file system settings and hook proc

2018-11-05 Thread Ævar Arnfjörð Bjarmason
On Sun, Nov 04 2018, Duy Nguyen wrote: > On Wed, Oct 31, 2018 at 9:53 PM Ben Peart wrote: >> >> +core.virtualFilesystem:: >> >> + If set, the value of this variable is used as a command which >> >> + will identify all files and directories that are present in >> >> + the worki

Re: [RFC v1] Add virtual file system settings and hook proc

2018-11-04 Thread Junio C Hamano
Ben Peart writes: >>> + if (*dtype == DT_UNKNOWN) >>> + *dtype = get_dtype(NULL, istate, pathname, pathlen); >> >> We try to defer paying cost to determine unknown *dtype as late as >> possible by having this call in last_exclude_matching_from_list(), >> and not here. If we are doing

Re: [RFC v1] Add virtual file system settings and hook proc

2018-11-04 Thread brian m. carlson
On Sun, Nov 04, 2018 at 07:34:01AM +0100, Duy Nguyen wrote: > On Wed, Oct 31, 2018 at 9:53 PM Ben Peart wrote: > > It's more than a dynamic sparse-checkout because the same list is also > > used to exclude any file/folder not listed. That means any file not > > listed won't ever be updated by git

Re: [RFC v1] Add virtual file system settings and hook proc

2018-11-03 Thread Duy Nguyen
On Wed, Oct 31, 2018 at 9:53 PM Ben Peart wrote: > >> +core.virtualFilesystem:: > >> + If set, the value of this variable is used as a command which > >> + will identify all files and directories that are present in > >> + the working directory. Git will only track and update fi

Re: [RFC v1] Add virtual file system settings and hook proc

2018-10-31 Thread Ben Peart
On 10/31/2018 3:11 PM, Duy Nguyen wrote: not really a review, just a couple quick notes.. Perfect! As an RFC, I'm more looking for high level thoughts/notes than a style/syntax code review. On Tue, Oct 30, 2018 at 9:40 PM Ben Peart wrote: From: Ben Peart On index load, clear/set

Re: [RFC v1] Add virtual file system settings and hook proc

2018-10-31 Thread Ben Peart
On 10/30/2018 7:07 PM, Junio C Hamano wrote: Ben Peart writes: diff --git a/config.c b/config.c index 4051e38823..96e05ee0f1 100644 --- a/config.c +++ b/config.c ... @@ -2307,6 +2311,37 @@ int git_config_get_index_threads(void) return 0; /* auto */ } +int git_config_get_virtual

Re: [RFC v1] Add virtual file system settings and hook proc

2018-10-31 Thread Duy Nguyen
not really a review, just a couple quick notes.. On Tue, Oct 30, 2018 at 9:40 PM Ben Peart wrote: > > From: Ben Peart > > On index load, clear/set the skip worktree bits based on the virtual > file system data. Use virtual file system data to update skip-worktree > bit in unpack-trees. Use virt

Re: [RFC v1] Add virtual file system settings and hook proc

2018-10-30 Thread Junio C Hamano
Ben Peart writes: > diff --git a/config.c b/config.c > index 4051e38823..96e05ee0f1 100644 > --- a/config.c > +++ b/config.c > ... > @@ -2307,6 +2311,37 @@ int git_config_get_index_threads(void) > return 0; /* auto */ > } > > +int git_config_get_virtualfilesystem(void) > +{ > + if (g

[RFC v1] Add virtual file system settings and hook proc

2018-10-30 Thread Ben Peart
From: Ben Peart On index load, clear/set the skip worktree bits based on the virtual file system data. Use virtual file system data to update skip-worktree bit in unpack-trees. Use virtual file system data to exclude files and folders not explicitly requested. Signed-off-by: Ben Peart --- We h