• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: move all files also with no extension via shell command
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: move all files also with no extension via shell command


  • Subject: Re: move all files also with no extension via shell command
  • From: "Mark J. Reed" <email@hidden>
  • Date: Fri, 6 May 2005 11:05:15 -0400

As long as you're moving files within the same filesystem, the mv command WILL preserve the resource fork.

However, if you're moving across filesystems, mv winds up calling cp behind the scenes, so the resource fork is lost.  I think you need to use ditto --rsrc followed by a separate delete step.  Which you can combine in a script, of course.


On 5/6/05, Jan-Bultereys <email@hidden> wrote:
thanks all for the input.

I have looked at the man pages from ditto but I can not find to delete the original files when files have been moved.

what I want is to ---move--- the files to an other directory and as you all pointed "with" the .rsrc data.

tell application "Finder"
        set mylist to (every item of folder Source)
        ------ Do some actions here -----
        try
                do shell script "ditto --rsrc " & Source & " " & destination & ""
        on error
                display dialog "does not work"
        end try
end tell

Is there an additional option to delete the source files?

best regards,jan

> ----------
> From:         applescript-users-bounces+jan.bultereys=email@hidden on behalf of Jake Pietrykowski
> Sent:         Wednesday, May 4, 2005 21:56 PM
> To:   AppleScript Users
> Subject:      Re: move all files also with no extension via shell command
>
> Load the developer tools... (/Developer/Tools/CpMac)
>
> CpMac works well. I prefer ditto --rsrc. rsync also can do the trick.
>
>
>
> On 5/4/05 1:52 PM, "Courtney Schwartz" <email@hidden> wrote:
>
> > Yeah. I've been dealing with them in ditto instead of cp or mv.
> >
> > Did I hear something about resource-aware custom versions of cp and mv
> > for Tiger, though?
> >
> >
> > On May 4, 2005, at 2:26 PM, Marc Rubin wrote:
> >
> >>
> >>> What is the shell command to move every file in a folder
> >>
> >> is anyone going to chime in about resource forks (.rsrc) and
> >> issues with approaching the filesystem through a shell?
> >>
> >>
> >
> >  _______________________________________________
> > Do not post admin requests to the list. They will be ignored.
> > Applescript-users mailing list      (
> Do not post admin requests to the list. They will be ignored.
> Applescript-users mailing list      (email@hidden)
> Help/Unsubscribe/Update your Subscription: email@hidden
>
>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      ( email@hidden>
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: move all files also with no extension via shell command
      • From: Christopher Nebel <email@hidden>
References: 
 >RE: move all files also with no extension via shell command (From: "Jan-Bultereys" <email@hidden>)

  • Prev by Date: Re: move all files also with no extension via shell command
  • Next by Date: Re: printing 2 sided pdf files w/out interaction
  • Previous by thread: Re: move all files also with no extension via shell command
  • Next by thread: Re: move all files also with no extension via shell command
  • Index(es):
    • Date
    • Thread