Newsgroups: comp.unix.wizards Path: utzoo!utgpu!cunews!bnrgate!bwdls61!pww From: pww@bnr.ca (Peter Whittaker) Subject: Re: file attributes Message-ID: <1991Jun26.151911.26381@bwdls61.bnr.ca> Sender: usenet@bwdls61.bnr.ca (Use Net) Nntp-Posting-Host: bwdls55 Organization: Bell-Northern Research, Ltd., Ottawa, Ontario, Canada References: <1743@sranha.sra.co.jp> <1991Jun26.011529.23375@cirrus.com> Date: Wed, 26 Jun 1991 15:19:11 GMT (It's been awhile since I've used the application discussed herein: advapologiesance for any errors....) dhesi@cirrus.com (Rahul Dhesi) wrote in <1991Jun26.011529.23375@cirrus.com>: >When I double-click on a C file, I don't always want to just compile >it. Sometimes I want to run lint on it instead. Other times I want to >expand tabs in it. Other times I want to enter my favorite editor to >edit that file. Other times I want to enter my favorite editor in >read-only mode to view that file. Other times I want to enter my >*second*-most favorite editor to edit that file, because I just happen >to need a feature at that instant that that second-most favorite editor >provides. OS/2 has an interesting feature that may be worthy of note: file extension associations. Since OS/2 comes out of the PC world, almost all filenames have a one to three character extension (i.e. prog.exe, proc.c, etc...). The OS/2 File System (a PM-based GUI for file system manipulation and exploration) allows you to associate executables with extensions, and vice versa. If you select an executable, and request an association, you will be prompted for a filename extension. Subsequent double clicks on filenames with the given extension will cause that executable to be launched against that file. Multiple associations are fine. In the case of multiple associations, double clicking a file will cause a modal dialog to appear, asking you to select the executable you wish to invoke against the file, i.e. I associate cc, lint, vi, and more, with the .c file extension Next, I double click on prog.c: the File System then asks me to choose which executable I wish to use against prog.c. As for arguments, you can specify default arguments when you make the original association. These can be overridden when you are selecting which executable to invoke, i.e. the modal dialogue presents you with a list of executables and their default arguments - you single the executable, then edit the argument list. Associations can be added, modified, and deleted at any time, and take effect immediately. Since the association information is part of the File System (which is, after all, an OS/2 application sitting on top of the DOS file system - such as it is :->), there is no meta-data in the file: you can safely ftp your source from a PS/2 to a Sun 4/490 without needing any esoteric resource/file discumbobulation. (IMHO) the OS/2 File System's "associations" are useful, workable, and sensible: they do not modify the files (BIG bonus - no new tools needed); they provide a quick and simple way to do default file handling (double click twice); they provide a convenient IF for changing default arguments; and they allow me to drop to the command line as if nothing had changed (since nothing has :->). (IMHO) if you want to put File Attributes into UNIX, do it in an application that sits above the FS: don't you *dare* modify my FS until you know that what you are doing works, works well, and meets my needs! (Let's not forget about backwards compatibility either: it's an ugly issue, but as UNIX begins to make inroads into the business world, and as more and more end users - i.e. not programmers, hackers, etc... - make use of UNIX as a daily tool, backwards compatibility will become more and more important. (IMHO) standards bloat is worse than kernel bloat: at least you can rewite the kernel and provide the same functionality, without disturbing anything that depends on it.... (is a :-> apropos?) -- Peter Whittaker [~~~~~~~~~~~~~~~~~~~~~~~~~~] Open Systems Support pww@bnr.ca [ ] Bell Northern Research Ph: +1 613 765 2064 [ ] P.O. Box 3511, Station C FAX:+1 613 763 3283 [__________________________] Ottawa, Ontario, K1Y 4H7