TYPE (DOS command)

From Wikipedia, the free encyclopedia
(Redirected from Type (OpenVMS command))
Jump to navigation Jump to search
type
DevelopersVarious open-source and commercial developers
Repository
  • {{URL|example.com|optional display text}}Lua error in Module:EditAtWikidata at line 29: attempt to index field 'wikibase' (a nil value).
Engine
    Lua error in Module:EditAtWikidata at line 29: attempt to index field 'wikibase' (a nil value).
    Operating systemRT-11, OS/8, RSX-11, TOPS-10, TOPS-20, VMS, CP/M, MP/M, CDOS, TRIPOS, HDOS, AmigaDOS, DOS, MSX-DOS, FlexOS, PC-MOS, SpartaDOS X, 4690 OS, OS/2, Windows, AROS, ReactOS, SymbOS
    PlatformCross-platform
    TypeCommand
    LicensePC-MOS: GPLv3
    AROS: AROS Public
    ReactOS: GPLv2

    In computing, type is a command in various command-line interpreters (shells) such as COMMAND.COM, cmd.exe, 4DOS/4NT and Windows PowerShell used to display the contents of specified files on the computer terminal. The analogous Unix command is cat.

    Implementations

    [edit | edit source]
    Description of the TYPE command of RT-11SJ displayed on a VT100.

    The command is available in the operating systems DEC RT-11,[1] OS/8,[2] RSX-11,[3] TOPS-10,[4] TOPS-20,[5] VMS, Digital Research CP/M,[6] MP/M,[7][8] MetaComCo TRIPOS,[9] Heath Company HDOS,[10] AmigaDOS,[11] DOS, FlexOS,[12] TSL PC-MOS,[13] SpartaDOS X,[14] IBM/Toshiba 4690 OS,[15] IBM OS/2, Microsoft Windows,[16] ReactOS,[17] AROS,[18] and SymbOS.[19]

    The type command is supported by Tim Paterson's SCP 86-DOS.[20] On MS-DOS, the command is available in versions 1 and later.[21] DR DOS 6.0 also includes an implementation of the TYPE command.[22]

    It is also available in the open source MS-DOS emulator DOSBox and the EFI shell.[23]

    In Windows PowerShell, type is a predefined command alias for the Get-Content Cmdlet which basically serves the same purpose. TYPE originated as an internal command in 86-DOS.

    The command-syntax and feature set between operating systems and command shell implementations can differ as can be seen in the following examples.

    DEC RT-11

    [edit | edit source]

    In Digital Equipment Corporation's RT-11, the command accepts up to six input file specifications. Multiple file specifications are separated with commas.

    The default filetype is .LST. Wildcards are accepted in place of filenames or filetypes.

    Syntax

    [edit | edit source]

    The command-syntax on RT-11 is:

    TYPE[/options] filespecs
    
    • COPIES:n – Specify the number of times the file will be typed
    • DELETE – Delete the file after typing it
    • LOG – Log the names of the files typed
    • NEWFILES – Only files dated with the current system date will be typed
    • NOLOG – Suppress the log of the files typed
    • QUERY – Require confirmation before typing each file
    • WAIT – Wait for user response before proceeding with the type

    Examples

    [edit | edit source]
    TYPE/COPIES:3 REPORT
    
    TYPE/NEWFILES *.LST
    

    DR CP/M, MP/M, FlexOS

    [edit | edit source]

    In Digital Research CP/M, the command expands tabs and line-feed characters (CTRL-I), assuming tab positions are set at every eighth column.

    The command does not support wildcard characters on FlexOS.[12]

    Syntax

    [edit | edit source]

    The command-syntax on CP/M is:

    TYPE ufn
    

    Note: ufn = unambiguous file reference

    In MP/M, the command has a pause mode. It is specified by entering a 'P' followed by two decimal digits after the filename. The specified number of lines will be displayed and then the command will pause until a carriage return is entered.[7]

    Examples

    [edit | edit source]
    A>TYPE FILE.PLM
    
    A>TYPE B:X.PRN
    
    0A>TYPE CODE.ASM P23
    

    TSL PC-MOS

    [edit | edit source]

    The Software Link's PC-MOS includes an implementation of TYPE. Like the rest of the operating system, it is licensed under the GPL v3.[24] It supports an option to display the file content in hexadecimal form.[13]

    Syntax

    [edit | edit source]

    The command-syntax on PC-MOS is:

    .TYPE filename [/h]
    
    • filename – The name of the file to display
    • /h – Display content in hexadecimal form

    Examples

    [edit | edit source]
    [A:\].TYPE FILE.BIN /h
    

    Microsoft Windows, OS/2, ReactOS

    [edit | edit source]
    The ReactOS type command

    The command supports wildcard characters. In Microsoft Windows and OS/2 it includes the filename in the output when typing multiple files.

    Syntax

    [edit | edit source]

    The command-syntax on Microsoft Windows and ReactOS is:

    type [Drive:][Path]FileName
    
    • [Drive:][Path]FileName – This parameter specifies the location and name of the file or files to view. Multiple file names need to be separated with spaces.
    • /? – This parameter displays help for the command.

    Examples

    [edit | edit source]
    C:\>type "my report.txt"
    
    C:\>type *.txt
    

    See also

    [edit | edit source]

    References

    [edit | edit source]
    1. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    2. ^ "Concise Command Language" (CCL).Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    3. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    4. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    5. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    6. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    7. ^ a b Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    8. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    9. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    10. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    11. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    12. ^ a b Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    13. ^ a b Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    14. ^ SpartaDOS X 4.48 User Guide
    15. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    16. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    17. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    18. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    19. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    20. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value). (59 pages)
    21. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    22. ^ DR DOS 6.0 User Guide Optimisation and Configuration Tips
    23. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    24. ^ Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).

    Further reading

    [edit | edit source]
    • Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    • Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    • Lua error in Module:Citation/CS1/Configuration at line 2172: attempt to index field '?' (a nil value).
    [edit | edit source]