HexType 2.52 Copyright (c) 1993-1996 Fredrik Wangel, All rights reserved --------------------------------------------------------------------(1/4)- .------------------------------------. | Û Û ÛÛÛÛÛ | | Û Û Û | | Û Û ÛÛÛÛ Û Û Û Û Û ÛÛÛÜ ÛÛÛÛ | | ÛÛÛÛÛ Û ÞÝÞÝ Û ÞÝÞÝ Û ÞÝÛ | | Û Û ÛÛÛ ÛÛ Û ÛÛ ÛÛÛß ÛÛÛ | | Û Û Û ÞÝÞÝ Û ÞÝ Û Û | | Û Û ÛÛÛÛ Û Û Û ÞÝ Û ÛÛÛÛ | | Hexa Extended Type | | 2.52a | | | |Copyright (c) 1993-96 Fredrik Wangel| `------------------------------------' NAME ht - display contents of files in ascii or hexadecimal SYNOPSIS ht [ filenames ] [ options ] DESCRIPTION For each of the filenames, which can include wildcards, a file matching the pattern is displayed in either normal ascii, ansi text(1) or hexadecimal, depending on the current options settings. A ini(3) file can be used to set the options differently for certain types of files or certain filenames. It is also possible to run external viewers for some files. If the output is not redirected or piped, a faster method of outputting is used as well as color in hex mode. Otherwise the normal stdout is used. If the HT.INI file is found options are read from it and used on files matching the entries therein. If extra options are put on the commandline, these will have a higher priority. The programs defaults have the lowest priority. For more information about the .ini file see (2). HexType 2.52 Copyright (c) 1993-1996 Fredrik Wangel, All rights reserved --------------------------------------------------------------------(2/4)- OPTIONS An option begin with a slash (/) or a hyphen (-) and can be one or more of the following (case insensitive): h Outputs all files in hexadecimal mode. e Hexadecimal output will be either 8 or 16 bytes per line. a Outputs all files in standard ASCII mode. p Page mode. Programs halts output at every full page. f FormFeed Sensitive. In ascii mode, formfeed characters (#12) will generate an empty page (do not use for printer output). i Put an information banner at top of screen. n No Even. Hex output uses full screen width. z FormFeed Zap. Turns off FormFeed Sensitive (use with printers). u Filter ASCII. In ascii mode, only certain characters are shown. Usefull when a text file turns out to contain binary data, or when you wish to see the text strings in an exe file. y Used with U to indicate Strict filter (only letters A..Z and a..z) w Removes strict filter. s No Pause. Prevents pauses every full page. o Output using stdout. rx Begins at line x in ASCII mode, percent x in HEX mode. In HEX max is 99, in ASCII max is no. lines in textfile. In HEX mode you could enter a hexadecimal number denoting the exact fileposition. Start with a $ character. tx Sets tabsize to x, where x is in [0..16]. Default is 8. cx Sets max columns to x, where x is in [1..255]. Default is the current screen's width. When a line exeeds max column in length, it is considered to be a new line. ! Displays some information about HT. ? Shows a short help text. note: /O disables pause, but you can still pipe to more etc. Information line will also be disabled. It is useful for viewing ansi documents though. The options are processed from left to right. An empty line will be added at the end of each file when reading multiple files to separate them. When viewing files the following keys have functions: s Skip to next file. n Turns off page mode (pause). p Turns on page mode (pause). spc Pauses. Press again to continue. q or esc Aborts program. EXAMPLES ht *.exe c:\prog\c\*.cpp /r$100 ht config.sys io.sys msdos.sys autoexec.bat HexType 2.52 Copyright (c) 1993-1996 Fredrik Wangel, All rights reserved --------------------------------------------------------------------(3/4)- DISCLAIMER AND WARRANTY THERE IS NO WARRANTY FOR THE PROGRAMS, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAMS "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAMS IS WITH YOU. SHOULD THE PROGRAMS PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY REDISTRIBUTE THE PROGRAMS AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAMS (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAMS TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. There is no warranty at all. Use at your own risk. This software is freeware. This means that you are free to do whatever you wish with both the source code and the executable as long as you do not remove the copyright notices. If you wish to distribute code using my routines, you must state this in some way, and you must include the complete ht archive too. And for good sports, give me a copy of it too, will you... Note that HT also uses NYA.TPU (or NYA.PAS), which is contained in the BUNCH.ZIP archive. This is only needed if you wish to recompile HT.PAS. Please read (3) too. If you make any improvements, find any bugs or have any suggestions on enhancements or additions, please contact me in a suitable way, see (0) HexType 2.52 Copyright (c) 1993-1996 Fredrik Wangel, All rights reserved --------------------------------------------------------------------(4/4)- FOOT NOTES (0) EMAIL: tde95waf@te.hik.se URL: http://www.student.te.hik.se/~tde95waf/index.html SNAIL: Fredrik Wangel Svedjev. 157 S-394 71 Kalmar SWEDEN VOICE: +46-480 47 91 91 FAX: +46-480 47 91 65 note: email and url are valid to at least autumn 1998. (1) To view ansi text you must pipe to more, ie HT file | more. (2) The ht.ini file should have the following entries: DefCmdLine= Extensions= Specials= Externals= DefCmdLine= This sets the default command line options. If DefCmdLine does not exist or is empty it defaults to DefCmdLine=/E Extensions= MoreExt= Enter here the extensions (eg EXE,PAS etc) and corresponding parameters in the form &x where x is a parameter (eg &H for hex). The parameters are valid to the end of extension list or to another &x that superseeds any other proceeding it, wich ever comes first (eg &h,EXE,&t3,&a,PAS). Remember to separate entries with a comma. MoreExt is used only to be able to split up the line to make editing easier. DO NOT TRY TO USE LINE BREAK ONLY! If Extension= or MoreExt= is not found at the beginning of the line it will be removed! (This is a bug (or feature) of SPX Lib and not HT) If nothing is entered the following will be default: Extensions=&h,COM,EXE,SYS MoreExt is empty by default. Specials= Enter here complete filenames (no path) and parameters to suit them. This will superseed any parameters regarding the file in the Extensions entry. Uses same form as in Extensions, eg &a,CONFIG.SYS. Default is Specials=&a,CONFIG.SYS Externals= MoreXtrns= This options makes it possible to view virtually any file. First enter the extension, then a colon (:) and the command that is to be executed. Spaces must be replaced with an underscore character (_). Put a %s where the filename is supposed to be. Separate different externals with a comma (,) eg Externals=ZIP:PKZIP_-vb_%s_|more,GIF:ALCHEMY_-v_%s MoreXtrns is used only to be able to split up the line to make editing easier. DO NOT TRY TO USE LINE BREAK ONLY! If Externals= or MoreXtrns= is not found at the beginning of the line it will be removed! (This is a bug (or feature) of SPX Lib and not HT) Default is Externals=ZIP:PKZIP_-vb_%s_|more,ARJ:ARJ_v_%s_|more MoreXtrns is empty by default. (3) This program uses the SPX_INI unit from The SPX Library v2.0 which is copyright 1993 Scott D. Ramsay. To compile the source code for HT you will need this library. You can download it (and you should, because it is great) using anonymous ftp at: ftp://nic.funet.fi/pub/msdos/games/programming/spx20.zip