A core command in the Mac OS Classic version of Tcl: http://www.purl.org/tcl/home/man/tcl8.4/TclCmd/resource.htm
Also available in Mac OS X through the TclResource package: http://sourceforge.net/projects/tclresource/