Open Files with Application

See the download page to obtain this program


This script starts applications for the files given as parameters. If a file extension is not given, a file with an extension is used if it is unique. If the file extension is not unique, the first one alphabetically is proposed and so on. Extensions ending with ~ or .backup are assumed to be backup files and are ignored. Files with a .lck extension are taken as lock files and are also ignored.

This program overrides the standard open. Its directory must therefore appear ahead of the directory for the standard open (i.e. /usr/bin/open) in $PATH.


Options of the standard open are respected:

-a app_name
the application name to use
print the file


As an example, file myfile.frame can be opened in the usual way:

  open myfile.frame

However, the point of the new command is to avoid having to specify the suffix:

  open myfile

This file could also be opened using

  open -a Edit myfile


First public version by Ken Turner, 13/12/95

Up one level to NEXTSTEP/OPENSTEP Utilities

Web Ken Turner Home   Email    Search Search Web Pages

Last Update: 15th July 2006