#2 'trash' fails to change dock icon

closed-wont-fix
nobody
None
1
2004-12-05
2004-11-12
Manuel Reiter
No

I've just downloaded osxutils-1.5 and noticed this minor glitch:

Moving something to the trash (I tried files and directories) from
the command line leaves the dock icon unchanged, i.e. as an
empty trashbin. Also, the popup option 'empty trash' remains
greyed out.

Otherwise, very nice and helpful tool, thanks a lot!

Discussion

  • Carsten Klapp
    Carsten Klapp
    2004-12-05

    • priority: 5 --> 1
    • status: open --> closed-wont-fix
     
  • Carsten Klapp
    Carsten Klapp
    2004-12-05

    Logged In: YES
    user_id=369655

    Unfortunately, there is a bug in the Finder and/or Dock which
    prevents the Trash icon from updating when files are moved into
    the Trash from the command line. This is still the case as of OS X
    10.3.6. See also: http://forums.macosxhints.com/showthread.php?
    t=19892

    There is no solution at the moment, but there are a couple of
    workarounds:

    To refresh the Trash icon in the Dock (thereby also activating the
    "Empty Trash" command in the Finder, when the Trash is indeed
    full), the Trash must first be opened. Perform one of the following:

    1) Click the Trash icon in the Dock to open it.
    or
    2) Run an applescript to open the Trash.

    2a) To open the Trash from within Apple Script Editor (you can for
    example, save this as a double-clickable AppleScript, but it would
    probably be easier to just click the Trash in the Dock):
    tell Application "Finder" to open the Trash

    2b) To open the Trash via an AppleScript from the Terminal, you
    can enter the following line into the Terminal:
    osascript -l AppleScript -e 'tell Application "Finder" to open Trash'

    2c) In the Terminal, create a shell script, perhaps named
    "opentrash" in your ~/bin, which could then be executed from the
    Terminal.

    mkdir -p ~/bin
    touch ~/bin/opentrash
    chmod a+x ~/bin/opentrash
    open -e ~/bin/opentrash
    [Next, enter the following two lines into the file opened with
    TextEdit and save it.]
    #!/bin/sh
    osascript -l AppleScript -e 'tell Application "Finder" to open Trash'

     
  • Carsten Klapp
    Carsten Klapp
    2004-12-05

    Logged In: YES
    user_id=369655

    Unfortunately, there is a bug in the Finder and/or Dock which
    prevents the Trash icon from updating when files are moved into
    the Trash from the command line. This is still the case as of OS X
    10.3.6. See also: http://forums.macosxhints.com/showthread.php?
    t=19892

    There is no solution at the moment, but there are a couple of
    workarounds:

    To refresh the Trash icon in the Dock (thereby also activating the
    "Empty Trash" command in the Finder, when the Trash is indeed
    full), the Trash must first be opened. Perform one of the following:

    1) Click the Trash icon in the Dock to open it.
    or
    2) Run an applescript to open the Trash.

    2a) To open the Trash from within Apple Script Editor (you can for
    example, save this as a double-clickable AppleScript, but it would
    probably be easier to just click the Trash in the Dock):
    tell Application "Finder" to open the Trash

    2b) To open the Trash via an AppleScript from the Terminal, you
    can enter the following line into the Terminal:
    osascript -l AppleScript -e 'tell Application "Finder" to open Trash'

    2c) In the Terminal, create a shell script, perhaps named
    "opentrash" in your ~/bin, which could then be executed from the
    Terminal.

    mkdir -p ~/bin
    touch ~/bin/opentrash
    chmod a+x ~/bin/opentrash
    open -e ~/bin/opentrash
    [Next, enter the following two lines into the file opened with
    TextEdit and save it.]
    #!/bin/sh
    osascript -l AppleScript -e 'tell Application "Finder" to open Trash'

     
  • Carsten Klapp
    Carsten Klapp
    2004-12-05

    Logged In: YES
    user_id=369655

    Unfortunately, there is a bug in the Finder and/or Dock which
    prevents the Trash icon from updating when files are moved into
    the Trash from the command line. This is still the case as of OS X
    10.3.6. See also: http://forums.macosxhints.com/showthread.php?
    t=19892

    There is no solution at the moment, but there are a couple of
    workarounds:

    To refresh the Trash icon in the Dock (thereby also activating the
    "Empty Trash" command in the Finder, when the Trash is indeed
    full), the Trash must first be opened. Perform one of the following:

    1) Click the Trash icon in the Dock to open it.
    or
    2) Run an applescript to open the Trash.

    2a) To open the Trash from within Apple Script Editor (you can for
    example, save this as a double-clickable AppleScript, but it would
    probably be easier to just click the Trash in the Dock):
    tell Application "Finder" to open the Trash

    2b) To open the Trash via an AppleScript from the Terminal, you
    can enter the following line into the Terminal:
    osascript -l AppleScript -e 'tell Application "Finder" to open Trash'

    2c) In the Terminal, create a shell script, perhaps named
    "opentrash" in your ~/bin, which could then be executed from the
    Terminal.

    mkdir -p ~/bin
    touch ~/bin/opentrash
    chmod a+x ~/bin/opentrash
    open -e ~/bin/opentrash
    [Next, enter the following two lines into the file opened with
    TextEdit and save it.]
    #!/bin/sh
    osascript -l AppleScript -e 'tell Application "Finder" to open Trash'

     
  • Carsten Klapp
    Carsten Klapp
    2004-12-05

    Logged In: YES
    user_id=369655

    What on earth is going on here... Why are there 3 replies? I am
    sure I submitted this only once!