All of lore.kernel.org
 help / color / mirror / Atom feed
From: Matthew Ruffalo <mmr15@case.edu>
To: Peter Krefting <peter@softwolves.pp.se>
Cc: Matthieu Moy <Matthieu.Moy@grenoble-inp.fr>,
	Johan Herland <johan@herland.net>,
	Git mailing list <git@vger.kernel.org>
Subject: Re: Having Git follow symlinks
Date: Fri, 31 Jan 2014 08:20:04 -0500	[thread overview]
Message-ID: <52EBA304.3000205@case.edu> (raw)
In-Reply-To: <alpine.DEB.2.00.1401311052370.3993@ds9.cixit.se>

On 01/31/2014 04:56 AM, Peter Krefting wrote:
> Matthieu Moy:
>
>> One option is to have the symlink in the other direction: make
>> /etc/foo a symlink to $GIT_WORKTREE/foo and version the later.
>
> I do that for the software that supports it, but ssh, for instance, is
> very picky that ~/.ssh is a directory and such. And at least one of
> the other files I version-control will be unlinked and overwritten in
> such a way that that does not work.
>
> I could split the repo up (that seems to be what "vcsh" is doing) and
> check the parts out in the corresponding directories, but I do like
> the idea of having one single repo.
>
>
> Oh, well, if I have the time, maybe I can come up with a patch. There
> is already some hacks in the "core.symlinks" setting, so I guess it
> should be possible.
>
This is now unrelated to Git, but I have .ssh symlinked to a
version-controlled directory on all of my machines (Kubuntu 13.10,
14.04, and recent Gentoo systems, but I've also done this on CentOS 5
and 6).

SSH doesn't care whether ~/.ssh is a symlink, but it *does* //care about
permissions:

"""
mruffalo@giygas:~$ ls -ld .ssh
lrwxrwxrwx 1 mruffalo mruffalo 13 Mar 17  2013 .ssh -> .home-git/ssh
mruffalo@giygas:~$ ls -ld .home-git
drwx------ 1 mruffalo mruffalo 116 Dec  8 01:26 .home-git
"""

If .home-git is mode 0755, SSH may refuse to use any private keys that
it finds, though I was unable to reproduce this with a few quick tests.

MMR...

  reply	other threads:[~2014-01-31 13:26 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-28 13:49 Having Git follow symlinks Peter Krefting
2014-01-28 14:47 ` Johan Herland
2014-01-30  9:01   ` Peter Krefting
2014-01-30 10:09     ` Christian Couder
2014-01-30 12:37     ` Matthieu Moy
2014-01-31  9:56       ` Peter Krefting
2014-01-31 13:20         ` Matthew Ruffalo [this message]
2014-01-31 17:23         ` Junio C Hamano
2014-01-31 17:56         ` Matthieu Moy

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=52EBA304.3000205@case.edu \
    --to=mmr15@case.edu \
    --cc=Matthieu.Moy@grenoble-inp.fr \
    --cc=git@vger.kernel.org \
    --cc=johan@herland.net \
    --cc=peter@softwolves.pp.se \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.