As in Windows or UNIX, A-Shell filespecs may be either partially or fully qualified. A fully qualified filespec consists of a device-unit, a filename, extension, and PPN, such as:
DSK0:SYSTAT.LIT[1,4]
The device-unit and [p,pn] together determine the directory location; see Directory Structure. A-Shell filespecs are not case sensitive. By convention, they are displayed in upper case, but are actually stored in the underlying host file system using lower case. This doesn't really matter in the Windows environment, which isn't case sensitive, but it is critical in UNIX. For example, the A-Shell filename MYSTUFF.DAT will be mapped to the host filename mystuff.dat. If the file is renamed outside of A-Shell to MyStuff.Dat, under UNIX it will be difficult to access the file from A-Shell without explicit quoting.
The set of legal filename characters is limited to the digits 0-9, letters A-Z, and the punctuation characters hyphen (-), underscore (_), dollar sign ($) and "at" sign (@). Spaces are not allowed.
The maximum length for a filespec, not counting the directory (i.e. device-unit and PPN) is 72 characters for the name and 8 for the extension. Many older applications limit themselves to an even shorter 6.3. See the DIR command for related details on display format options.
Everything except the filename can be omitted, with the missing parts supplied automatically by the context. For example:
Entered |
Interpreted As |
DIR.LIT[1,4] |
DIR.LIT in [1,4] of device where currently logged in |
GO.CMD |
GO.CMD in device-PPN where currently logged in |
MYSRC:MENU.BAS |
MENU.BAS in location of ersatz directory MYSRC: |
LOG |
LOG.LIT in DSK0:[1,4] or local dir, or LOG.CMD or LOG.DO in DSK0:[2,2] |
In most contexts, particularly inside of a program, native filespecs can also be used in place of A-Shell filespecs. The advantage of the A-Shell filespecs is that by being virtualized, they insulate your code from the specific details of the disk environment.