hi.
the c:copy command is not able to copy links. maybe this can be added? uisng the workbench for copying this works.
there exists the COPYLINKS arcgument and the FOLLOWLINKS argument. but a "keeplink" (or whatever) is missing.
btw. i personally would expect that a
copy #? TO whatever: ALL CLONE
really copies everything so that the target folder looks identical to the source one. so a "keelinks" should be the default if possible.
i just found this annoying when i reformated some of my partitions. i copied the content before to an empty partition and back afterwards. but lost the links in sobj: for example.
thanks and regards
michael
c:copy command and links
- MichaelMerkel
- Beta Tester
- Posts: 355
- Joined: Mon Dec 20, 2010 2:08 pm
- Location: Germany
- Contact:
c:copy command and links
Michael Merkel
(Member of Amiga Freunde Pfalz)
(Member of Amiga Freunde Pfalz)
- nbache
- Beta Tester
- Posts: 1716
- Joined: Mon Dec 20, 2010 7:25 pm
- Location: Copenhagen, Denmark
- Contact:
Re: c:copy command and links
I agree, I'd like this too. It has been discussed before, AFAIR.
It is not so simple, though, as it would also have to be checked whether the target of the link is inside or outside the directory hierarchy being copied. If inside, the link must be created after the target has been created in the copy (unless it's a soft link), so an extra pass/step is necessary. I'm not sure whether Workbench handles this?
But of course it could be done, conceptually. Whether it is feasible reasonably to make the existing copy command do it, I don't know.
Best regards,
Niels
It is not so simple, though, as it would also have to be checked whether the target of the link is inside or outside the directory hierarchy being copied. If inside, the link must be created after the target has been created in the copy (unless it's a soft link), so an extra pass/step is necessary. I'm not sure whether Workbench handles this?
But of course it could be done, conceptually. Whether it is feasible reasonably to make the existing copy command do it, I don't know.
Best regards,
Niels
Re: c:copy command and links
I wrote my own command to backup hard/soft links (and optionally other Amiga-specific stuff like comments)...
Re: c:copy command and links
With 'cp -a <src> <dst>' from SDK does what you want to do, or am I wrong?
nexus
P.S. With long filenames and weird characters in files, the AmigaOS Copy Command has problems, too, as far as I remember. I usually prefere using 'cp' for this reason.
nexus
P.S. With long filenames and weird characters in files, the AmigaOS Copy Command has problems, too, as far as I remember. I usually prefere using 'cp' for this reason.
- MichaelMerkel
- Beta Tester
- Posts: 355
- Joined: Mon Dec 20, 2010 2:08 pm
- Location: Germany
- Contact:
Re: c:copy command and links
never tried that! i'll check - thanks!nexus wrote:With 'cp -a <src> <dst>' from SDK does what you want to do, or am I wrong?
nexus
P.S. With long filenames and weird characters in files, the AmigaOS Copy Command has problems, too, as far as I remember. I usually prefere using 'cp' for this reason.
regards...
michael
Michael Merkel
(Member of Amiga Freunde Pfalz)
(Member of Amiga Freunde Pfalz)
- MichaelMerkel
- Beta Tester
- Posts: 355
- Joined: Mon Dec 20, 2010 2:08 pm
- Location: Germany
- Contact:
Re: c:copy command and links
nexus wrote:With 'cp -a <src> <dst>' from SDK does what you want to do, or am I wrong?
thank you so much! that's working perfect. super!
nevertheless should the original copy command be enhanced. expecially because it is faster.
thanks and regards
michael
Michael Merkel
(Member of Amiga Freunde Pfalz)
(Member of Amiga Freunde Pfalz)
Re: c:copy command and links
Copying a directory per workbench works perfect! Indeed C:Copy exempts links from copying.
I therefore mostly use WB's copy.
OldFart
I therefore mostly use WB's copy.
OldFart
X5000, appears to be sick. Dismantled jan 1, 2024.
Dead MicroA1
A1200 in ElBox, c/w Blizzard '040 @ 50MHz + SCSI module, ZIV-board c/w (o.a.) cv64/3d + flickerdoubler + FastATA-ZIV + Lots of SCSI gear, sitting idle.
RaspBerry Pi 2B, 3B, 4B/4Gb, 4B/8Gb
OrangePi 5+ 8Gb
ACER Windows 10
Dead MicroA1
A1200 in ElBox, c/w Blizzard '040 @ 50MHz + SCSI module, ZIV-board c/w (o.a.) cv64/3d + flickerdoubler + FastATA-ZIV + Lots of SCSI gear, sitting idle.
RaspBerry Pi 2B, 3B, 4B/4Gb, 4B/8Gb
OrangePi 5+ 8Gb
ACER Windows 10
Re: c:copy command and links
Mate...thank younexus wrote:With 'cp -a <src> <dst>' from SDK does what you want to do, or am I wrong?
nexus
P.S. With long filenames and weird characters in files, the AmigaOS Copy Command has problems, too, as far as I remember. I usually prefere using 'cp' for this reason.
I was looking for a solution myself for ages
People are dying.
Entire ecosystems are collapsing.
We are in the beginning of a mass extinction.
And all you can talk about is money and fairytales of eternal economic growth.
How dare you!
– Greta Thunberg
Entire ecosystems are collapsing.
We are in the beginning of a mass extinction.
And all you can talk about is money and fairytales of eternal economic growth.
How dare you!
– Greta Thunberg
- MichaelMerkel
- Beta Tester
- Posts: 355
- Joined: Mon Dec 20, 2010 2:08 pm
- Location: Germany
- Contact:
Re: c:copy command and links
... and one problem with the "cp" command... the "S" flag is not copied. suddenly some scripts did not work. and that was caused by the former "cp"...MichaelMerkel wrote:nexus wrote:With 'cp -a <src> <dst>' from SDK does what you want to do, or am I wrong?
thank you so much! that's working perfect. super!
nevertheless should the original copy command be enhanced. expecially because it is faster.
regards...
michael
Michael Merkel
(Member of Amiga Freunde Pfalz)
(Member of Amiga Freunde Pfalz)
Re: c:copy command and links
Links (at least soft links) get copied with a WorkBench drag-n-drop copy. Maybe the problem is in dos.library rather than the copy command because Dopus4 botches links too. I tried the OS3 copy command but it copies the soft links as directories! Apparently, "cp" works but doesn't handle all the protection bits correctly. If the OS is going to use links (SOBJS directory & SDK:gcc/bin directory) we should at least get a copy command that copies them properly. Some of us actually back up our partitions on a regular basis and prefer that the links are there if a restore is necessary.nbache wrote:But of course it could be done, conceptually. Whether it is feasible reasonably to make the existing copy command do it, I don't know.
AmigaOne X1000 with 2GB memory - OS4.1 FE