From: Robin Rosenberg <robin.rosenberg@dewire.com>
To: Michael J Gruber <git@drmicha.warpmail.net>
Cc: Junio C Hamano <gitster@pobox.com>, git@vger.kernel.org
Subject: Re: [PATCH] RFC Optionally handle symbolic links as copies
Date: Wed, 12 Dec 2012 17:15:14 +0100 (CET) [thread overview]
Message-ID: <1141725649.20938344.1355328914240.JavaMail.root@dewire.com> (raw)
In-Reply-To: <50C89822.9050900@drmicha.warpmail.net>
----- Ursprungligt meddelande -----
> Robin Rosenberg venit, vidit, dixit 06.12.2012 02:23:
> >
> >
> > ----- Ursprungligt meddelande -----
> >> Robin Rosenberg <robin.rosenberg@dewire.com> writes:
> >>
> >>> If core.symlinks is set to copy then symbolic links in a git
> >>> repository
> >>> will be checked out as copies of the file it points to.
> >>
> >> That all sounds nice on surface when the primary thing you care
> >> about is to fetch and check out other people's code and extract it
> >> to the working tree, but how well would that work on the checkin
> >> side? What happens if I check out a symlink that points at a file
> >> (either in-tree or out-of-tree), make some changes that do not
> >> involve the symlink, and before I make the commit, an unrelated
> >> change is made to the file the symlink is pointing at?
> >>
> >>> - git status - when do we report a diff.
> >>> - After checkout we should probably not
> >>> - if the "linked" files change?
> >>
> >> Yeah, exactly.
> >>
> >>> - if a change in the copied directory chsnges
> >>
> >> That, too.
> >>
> >>> - if a file in the copied diretory is added/removed
> >>> - update, should we update the copied structure automatically
> >>> when the link target changes
> >
> > Some of the questions have proposals in the includes test script. A
> > little more dangerous than having real symlinks ofcourse, but
> > regardless
> > of what one does with or without copied symlinks one can make
> > mistakes
> > and I feel letting Git do the copying is way better than having
> > real
> > copies in the git repository. Another crappy scm which the users
> > are
> > converting from does this and it works. A difference to git is that
> > it (ok clearcase) makes all files read-only so there are fewer mays
> > of making mistakes with the copies.
> >
> >> I personally do not think this is worth it. It would be very
> >> useful
> >> on the export/checkout side, so it may make sense to add it to
> >> "git
> >> archive", though.
> >
> > It makes sense, but it does not solve the problem at hand.
> >
> > -- robin
> >
>
> Well, what is the problem at hand?
The problem is that I'm converting a repo from clearcase to git and
there are lots of symbolic links. Symbolic links in clearcase on
Windows is treated as file copy in snapshot views which means that
you get a copy of the linked file when you update the view. If the
link target changes you can update your view to refersh your copies.
> Your commit message begins in present tense as if it described the
> current state of git, when in fact it describes what the patch is
> about
> to achieve. This is confusing enough already,
You're right.
> I don't see any mention of the purpose, other than "content may be
> used", which would be served perfectly by a copy-on-link feature on
> the
> export side, as mentioned by Junio. Is git-archive|tar an option?
I want the copy on checkout. The intent is to change things and
then commit.
Perhaps I can convince people to let a script copy stuff instead.
-- robin
next prev parent reply other threads:[~2012-12-12 16:15 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-05 22:46 [PATCH] RFC Optionally handle symbolic links as copies Robin Rosenberg
2012-12-05 23:51 ` Junio C Hamano
2012-12-06 1:23 ` Robin Rosenberg
2012-12-12 14:43 ` Michael J Gruber
2012-12-12 16:15 ` Robin Rosenberg [this message]
2012-12-12 20:22 ` Junio C Hamano
2012-12-06 6:59 ` Johannes Sixt
2012-12-06 11:51 ` Robin Rosenberg
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=1141725649.20938344.1355328914240.JavaMail.root@dewire.com \
--to=robin.rosenberg@dewire.com \
--cc=git@drmicha.warpmail.net \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
/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).