git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andreas Ericsson <ae@op5.se>
To: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Cc: git@vger.kernel.org
Subject: Re: git /objects directory created 755 by default?
Date: Thu, 22 Dec 2005 17:52:39 +0100	[thread overview]
Message-ID: <43AAD9D7.1070503@op5.se> (raw)
In-Reply-To: <Pine.LNX.4.63.0512221700310.18982@wbgn013.biozentrum.uni-wuerzburg.de>

Johannes Schindelin wrote:
> Hi,
> 
> this is getting silly. The problem is: how to setup a shared repository, 
> i.e. a repository into which different users can push their updates.
> 

You're simplifying. Your question was
"How can I set up a repository for multiple users to write to without 
setting a global umask for non-interactive shells?"

Junio said:
"I agree the setting should not be limited to git-shell, but I do
not think setting "umask" from git configuration is the right
way either.  For files and directories under $GIT_DIR, maybe
imposing the policy git configuration file has is OK, but I
think honoring the user's umask is the right thing for working
tree files."

which I whole-heartedly agree with. I'd be completely furious if a tool 
ignored the umask I use for checking out files of a local repository 
just because I happen to do some work at the machine where the repo is 
stored (I imagine this couldn't possibly affect repositories cloned 
remotely, although that would surely have me going ballistic).

You answered that it would be good for hooks as well, although those can 
set their own umask easily enough (if you forget it there, you'll be 
hastily reminded the first time it breaks, so no real harm done).

The problem as I see it is to update only the $GIT_DIR files with the 
proper umask (or rather, just the objects/ and refs/ directories, since 
$GIT_DIR/. is never touched after being created and the other are for 
repo maintainers only).

Enter the nifty git-receive-pack, which does all the writing when a repo 
is being pushed to, unless bypassed from the /git/foo working tree for 
the /git/foo/.git repository. The latter is already discouraged, so we 
might as well ignore that. It's also nice because it will never mess 
with files that are for the repo maintainer only, although hooks can 
ofcourse do whatever they like to those files provided the repo 
maintainer allows it.

Now it's time to go home, but I'll have a patch by tonight unless you 
beat me to it. :)

-- 
Andreas Ericsson                   andreas.ericsson@op5.se
OP5 AB                             www.op5.se
Tel: +46 8-230225                  Fax: +46 8-230231

  reply	other threads:[~2005-12-22 16:52 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-12-20 23:25 git /objects directory created 755 by default? Martin Langhoff
2005-12-20 23:43 ` Junio C Hamano
2005-12-21  1:37   ` Junio C Hamano
2005-12-21  2:28     ` Martin Langhoff
2005-12-21  4:53       ` Junio C Hamano
2005-12-21  5:10         ` Martin Langhoff
2005-12-21  5:03       ` Junio C Hamano
2005-12-21  5:15         ` Martin Langhoff
2005-12-21  5:17           ` Junio C Hamano
2005-12-21  5:23             ` Martin Langhoff
2005-12-22  3:46           ` Ben Clifford
2005-12-21 15:35     ` Johannes Schindelin
2005-12-21 22:10       ` Junio C Hamano
2005-12-21 22:20         ` Johannes Schindelin
2005-12-22  9:45           ` Andreas Ericsson
2005-12-22 11:27             ` Johannes Schindelin
2005-12-22 12:28               ` Andreas Ericsson
2005-12-22 14:37                 ` Johannes Schindelin
2005-12-22 15:53                   ` Andreas Ericsson
2005-12-22 16:03                     ` Johannes Schindelin
2005-12-22 16:52                       ` Andreas Ericsson [this message]
2005-12-22 17:31                         ` Johannes Schindelin
2005-12-22 19:14                         ` Junio C Hamano
2005-12-22 19:28                           ` Johannes Schindelin
2005-12-22 20:15                             ` Junio C Hamano
2005-12-22 20:27                               ` Johannes Schindelin
2005-12-23  4:19                 ` Junio C Hamano
2005-12-23 12:07                   ` Andreas Ericsson
2005-12-22 10:11           ` Alex Riesen
2005-12-22 11:35             ` Johannes Schindelin
2005-12-22 14:38               ` Alex Riesen
2005-12-22 15:09                 ` Johannes Schindelin
2005-12-22 15:14                   ` Alex Riesen
2005-12-22 15:52                     ` Johannes Schindelin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=43AAD9D7.1070503@op5.se \
    --to=ae@op5.se \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).