GNU bug report logs -
#33573
--add-missing --copy should replace symlinks with real files
Previous Next
Full log
View this message in rfc822 format
Karl Berry <karl <at> freefriends.org>, Fri Dec 30 2022 00:33:03 GMT+0100
(Central European Standard Time)
> Another simple patch from my side: when '--copy' given to
> '--add-missing', copy the standard files even if symlinks already exist.
>
> I am not sure about changing the behavior here. Although the behavior
> you propose is plausible, I fear that people might depend or expect on
> failure if symlinks exist. It doesn't seem bad to me to require the user
> to clean up their own symlinks, instead of assuming the overwriting
> should be done. There's no way to know what the situation really is.
>
> What I suggest is making the new behavior of deleting existing symlinks
> iff -f is *also* given. If the user says "force" and "copy" then ok, we
> can figure they're asking for what they're getting.
>
> Wdyt? --thanks, karl.
Hi.
Sure, no problem from my side. This is actually already the current
behavior, from what I see (but I didn't check in detail). Someone
reported a bug for this, so I simply gave it a try.
The user has a point: --copy was given, but the files were not copied.
This may be a bit confusing. But this depends on the point of view, I
guess, and both behaviors have a point and can be correct, depending
on who you're asking. We can as well leave the current behavior, as
you say: make the user be clear about what they want and maybe allow
Automake one day behave differently (like exit with an error if a
symlink exists and -c given, but no -f, etc.).
Just maybe make something clearer in the documentation and/or the help
message in such case, like:
--help:
[...]
-c, --copy with -a, copy missing files if they or their
symlinks don't already exist (default is symlink)
-f, --force-missing force update of standard files (with -c copies
the files even if symlinks exist)
Automake docs:
‘-c’
‘--copy’
When used with ‘--add-missing’, causes installed files to be
copied if files or symlinks don't already exist. The default is
to make a symbolic link.
> P.S. I hope to reply to your other patch in the next day or two.
No problem - thanks for confirmation that they actually arrived. I
thought the mails got lost in some black hole, because I'm not
subscribed and I didn't see them in the mailing list's archive :).
--
Regards - Bogdan ('bogdro') D. (GNU/Linux & FreeDOS)
X86 assembly (DOS, GNU/Linux): http://bogdro.evai.pl/index-en.php
Soft(EN): http://bogdro.evai.pl/soft http://bogdro.evai.pl/soft4asm
www.Xiph.org www.TorProject.org www.LibreOffice.org www.GnuPG.org
This bug report was last modified 2 years and 164 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.