#!/bin/sh # show_getinfo # This script opens the Finder's "Get Info" window # for the file or folder specified as a command-line argument. # Cameron Hayne (macdev@hayne.net) March 2003 scriptname=`basename $0` if [ $# -lt 1 ]; then echo "Usage: $scriptname file_or_folder" exit fi path=$1 if [ ! -e $path ]; then echo "$scriptname: $path: No such file or directory" exit fi case $path in /*) fullpath=$path ;; ~*) fullpath=$path ;; *) fullpath=`pwd`/$path ;; esac if [ -d $fullpath ]; then file_or_folder="folder" else file_or_folder="file" fi /usr/bin/osascript > /dev/null <