Send file to all users desktop

Discussion in 'Mac Programming' started by Flyinace2000, Dec 8, 2008.

  1. Flyinace2000 macrumors 6502a

    Flyinace2000

    Joined:
    Sep 28, 2004
    #1
    I need to distribute a .webloc file to all students at on of my K-4 buildings. The homedir structure is:

    HomeDirs/Students/GRADE YEAR/USERNAME/

    There are 5 grade years folders and about 100 students in each. Where should I start?

    Thanks

    -Will
     
  2. Sayer macrumors 6502a

    Sayer

    Joined:
    Jan 4, 2002
    Location:
    Austin, TX
    #2
    Applescript would probably be the quickest. Maybe Automator. If all the home folders are on one server that's easy enough to do.

    If they are on different Macs, then if you had Apple Remote Desktop (ARD) you could use that to send the files from one central location.

    Once the problem is more clearly defined, a solution can be described.
     
  3. Flyinace2000 thread starter macrumors 6502a

    Flyinace2000

    Joined:
    Sep 28, 2004
    #3
    All the HomeDirs are on one server. I am very new to Apple Script. Is there a template i can use to modify.
     
  4. Flyinace2000 thread starter macrumors 6502a

    Flyinace2000

    Joined:
    Sep 28, 2004
    #5
  5. ke5go macrumors newbie

    Joined:
    Dec 13, 2008
    #6
    use a shell script

    Did you ever get this done?

    Assuming you have the master.webloc in your home directory, then something like the following tcsh script would copy that file to each of the students' directories.


    cd HomeDirs/Students/
    foreach grade (`find . -maxdepth 1 -type d -print`)
    foreach student (`find ./$grade -maxdepth 1 -type d -print`)
    echo cp ~/master.webloc ./$grade/$student/.webloc
    end
    end

    After you have this working and it displays all of the commands to be executed the way you want, then just remove the "echo" from the command and it will actually execute the commands.

    JimS
     
  6. Flyinace2000 thread starter macrumors 6502a

    Flyinace2000

    Joined:
    Sep 28, 2004
    #7
    I will give this a shot tomorrow. Thanks.

    For now i simply put one copy in in each teachers hand out folder. Thanks again
     

Share This Page