Can I copy files (mp3) to flash drive WITHOUT copying invisible files?

Discussion in 'Apple' started by Jo, Mar 30, 2009.

  1. Jo

    Jo Guest

    I have a new car radio that includes a USB port. Plug in a flash drive
    (formated with FAT 16/32) with MP3 files, and the car radio can find
    and play the mp3 files. Cool...BUT...the radio chokes on the invisible
    files that the Mac creates. Is there a way to copy files on a Mac
    (latest 10.5.6 OS) to a FAT-formatted PC USB Flash Drive WITHOUT
    copying all those invisible files (the ones that start with a period)?
    Jo, Mar 30, 2009
    1. Advertisements

  2. Jo

    Warren Oates Guest

    You should just be able to delete them before you unplug the flash
    drive. You might need to use the terminal.
    Warren Oates, Mar 30, 2009
    1. Advertisements

  3. Jo

    E Z Peaces Guest

    I use Kopymac (freeware). I can clean a whole folder before
    transferring files to a flash drive, and I think I can clean what's
    already on the drive. V 3.0 is good for PPC with classic through Intel
    with 10.5.
    E Z Peaces, Mar 31, 2009
  4. Jo

    Tom Stiller Guest

    find someFolder -iname ".[^.]*" -exec rm -r {} \;
    which removes all files and folders whose name begins with a dot
    followed by at least one non-dot.
    Tom Stiller, Mar 31, 2009
  5. Jo

    Henri Guest

    WWeellll, ...possibly. I must confess I never tried to investigate the
    mechanics of that script. All I know is that it does remove everything
    objectionable from wherever I tell it to.
    But I will put the above bit somewhere safe, in case the need arises.

    Henri, Mar 31, 2009
  6. Jo

    Ian Gregory Guest

    If I ran that on my home directory I would lose loads of important
    stuff, eg everything in my .gnupg directory including my my own private
    key and all the publc keys I have saved, my .muttrc file, my .msmtprc
    file (without which I would no longer be able to send email), my .ssh
    directory containing host keys of known hosts etc.

    Whilst there may be a few dot files that some people may not need or
    want, deleting all dot files is probably more undesirable in general
    than deleting all files that begin with (for example) the letter "p".

    Ian Gregory, Mar 31, 2009
  7. Jo

    Tom Stiller Guest

    Yeah but the OP wanted to remove the "hidden" files from his flash drive
    for use in his auto, hardly his home directory.
    Tom Stiller, Mar 31, 2009
  8. Jo

    Ian Gregory Guest

    Fair enough, I missed that. On the other hand there does seem to be a
    worrying tendency for people to say "I don't want these files, how can I
    get rid of them?" without considering that they may be there for a
    reason. I was not accusing you or the OP, just pointing out the danger
    of running that find command willy-nilly.

    Ian Gregory, Mar 31, 2009
  9. Jo

    Warren Oates Guest

    That wasn't the reason for the script. If you copy audio files to a usb
    stick for subsequent processing on the dark side, you don't need any dot
    files at all and they can all be safely removed. No, of course you don't
    want to run a script like that on your home directory, fergawdsake.
    Personally, I would just rm the files before I ejected the stick from my
    Mac, but that's just me. Well, I dunno, maybe I'd write a complicated
    awk script or something.

    I ban't say words with b in them, silly bunt that I am.
    Warren Oates, Mar 31, 2009
  10. Jo

    Ian Gregory Guest

    OK, I know I shouldn't have missed it because it was in the Subject:
    although to be fair you provided a solution for deleting invisible files
    whereas the OP wanted to copy all files except invisible files which
    could be done directly using something like:

    rsync -r --exclude ".*" SomeFolder/ SomeOtherFolder

    Ian Gregory, Mar 31, 2009
  11. Jo

    Tom Stiller Guest

    Yah, but that wouldn't get the hidden files that the Finder puts there
    automatically e.g. .Spotlight-V100, .Trashes, or .fseventsd.
    Tom Stiller, Mar 31, 2009
  12. Jo

    Tim Murray Guest

    I use a very handy system pref called BlueHarvest from
    Works in the background on servers, USB sticks, etc., and is highly
    Tim Murray, May 24, 2009
  13. Jo

    Király Guest

    Here's another similar app. It doesn't look nearly as configurable as
    BlueHarvest, but it's free.
    Király, May 24, 2009
  14. Jo

    E Z Peaces Guest

    E Z Peaces, May 26, 2009
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.