How to make a script

Discussion in 'macOS' started by lamina, Oct 3, 2006.

  1. lamina macrumors 68000

    lamina

    Joined:
    Mar 9, 2006
    Location:
    From Canada, living in Seoul
    #1
    The dock sometimes crashes on my iMac, and I don't want my family to have to go to terminal and type killall Dock, so is there a way I can make a script file that they can double-click on the desktop to run that command?
     
  2. gauchogolfer macrumors 603

    gauchogolfer

    Joined:
    Jan 28, 2005
    Location:
    American Riviera
    #2
    Why not write an AppleScript with that exact command, and save it on the desktop as a self-contained script? Then they could double-click on it as you said.

    Or, they could 'Force Quit' the dock from within Application Monitor.
     
  3. beatsme macrumors 65816

    beatsme

    Joined:
    Oct 6, 2005
    #3
    open up Script Editor, and enter this:
    tell application "Terminal"
    activate
    do script with command "killall Dock"
    end tell
    tell application "Terminal"
    activate
    do script with command "killall Terminal"
    end tell


    Save it as whatever you want. I named it "killDock"
    This will open Terminal, kill the Dock, and close Terminal.
     
  4. lamina thread starter macrumors 68000

    lamina

    Joined:
    Mar 9, 2006
    Location:
    From Canada, living in Seoul
  5. gauchogolfer macrumors 603

    gauchogolfer

    Joined:
    Jan 28, 2005
    Location:
    American Riviera
    #5
    Ah, sorry, then use beatsme's approach.
     

Share This Page