Re: [PATCH 13/16] init: allow alternate backends to be set for new repos

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 2015-12-23 at 14:34 +0100, Michael Haggerty wrote:
> On 12/03/2015 01:35 AM, David Turner wrote:
> > git init learns a new argument --refs-backend-type.  Presently,
> > only
> > "files" is supported, but later we will add other backends.
> > 
> > When this argument is used, the repository's core.refsBackendType
> > configuration value is set, and the refs backend's initdb function
> > is
> > used to set up the ref database.
> > 
> > Signed-off-by: David Turner <dturner@xxxxxxxxxxxxxxxx>
> > ---
> >  Documentation/git-init-db.txt |  2 +-
> >  Documentation/git-init.txt    |  6 +++++-
> >  builtin/init-db.c             | 10 ++++++++++
> >  cache.h                       |  2 ++
> >  config.c                      | 20 ++++++++++++++++++++
> >  environment.c                 |  1 +
> >  path.c                        | 32 ++++++++++++++++++++++++++++++-
> > -
> >  refs.c                        |  8 ++++++++
> >  refs.h                        | 12 ++++++++++++
> >  setup.c                       | 10 ++++++++++
> >  10 files changed, 99 insertions(+), 4 deletions(-)
> > 
> > diff --git a/Documentation/git-init-db.txt b/Documentation/git-init
> > -db.txt
> > index 648a6cd..72fbd71 100644
> > --- a/Documentation/git-init-db.txt
> > +++ b/Documentation/git-init-db.txt
> > @@ -9,7 +9,7 @@ git-init-db - Creates an empty Git repository
> >  SYNOPSIS
> >  --------
> >  [verse]
> > -'git init-db' [-q | --quiet] [--bare] [-
> > -template=<template_directory>] [--separate-git-dir <git dir>] [-
> > -shared[=<permissions>]]
> > +'git init-db' [-q | --quiet] [--bare] [-
> > -template=<template_directory>] [--separate-git-dir <git dir>] [-
> > -shared[=<permissions>]] [--refs-backend-type=<name>]
> >  
> >  
> >  DESCRIPTION
> > diff --git a/Documentation/git-init.txt b/Documentation/git
> > -init.txt
> > index 8174d27..9ea6753 100644
> > --- a/Documentation/git-init.txt
> > +++ b/Documentation/git-init.txt
> > @@ -12,7 +12,7 @@ SYNOPSIS
> >  'git init' [-q | --quiet] [--bare] [-
> > -template=<template_directory>]
> >  	  [--separate-git-dir <git dir>]
> >  	  [--shared[=<permissions>]] [directory]
> > -
> > +	  [--refs-backend-type=<name>]
> 
> ISTM that "backend" (used here in this option name, and in the
> manpage)
> is not such a meaningful term to users. Could we pick a less obscure
> term? E.g., maybe "--ref-storage=<name>"?

I'm working on the rest now, but wanted to comment on this first.  I
went ahead and made this change, but I'm not sure I like it.  In the
git codebase, the concept will continue to be called "backend"; there
are already-accepted patches using that terminology.  Having two
separate names for the same thing seems confusing to me.  We have this
problem already with the index ("cache" or "staging area"), which is a
little annoying when grepping the code. 

(For refs-backend-type, the name of the config variable is a third
separate thing, where we'll have to choose between the internal and the
external name).  

So I think maybe we should just go with refs-backend here.  What do
others think?

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]