Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
more(1)			    General Commands Manual		       more(1)

NAME
       more, page - file perusal filter	for crt	viewing

SYNOPSIS
       number]	command]  tagstring]  tabs] option] linenumber]	pattern] [name
       ...]

       number] command]	tagstring] tabs] option]  linenumber]  pattern]	 [name
       ...]

   REMARKS:
       is  preferred  in  some standards and has some added functionality, but
       does not	support	character highlighting (see pg(1)).

DESCRIPTION
       is a filter for examining continuous text, one screenful	at a time,  on
       a soft-copy terminal.  It is quite similar to and is retained primarily
       for backward compatibility.   normally  pauses  after  each  screenful,
       printing	 the filename at the bottom of the screen. To display one more
       line, press To display another screenful	press Other possibilities  are
       described later.

       and  differ  only slightly.  scrolls the	screen upward as it prints the
       next page.  clears the screen and prints	a new screenful	of  text  when
       it prints a new page.  Both provide one line of overlap between screen-
       fuls.

       name can	be a filename or specifying standard  input.   processes  file
       arguments in the	order given.

       supports	the Basic Regular Expression syntax (see regexp(5)).

       recognizes the following	command	line options:

	      Set the number of	lines in the display window to
			     number,  a	positive decimal integer.  The default
			     is	one line less than the	the  number  of	 lines
			     displayed	by the terminal; on a screen that dis-
			     plays 24 lines, the default is 23.	The flag over-
			     rides any values obtained from the	environment.

	      Same as	     except that the number of lines is	set to n.

	      Draw each	page by	beginning at the top of	the screen,
			     and  erase	 each  line just before	drawing	on it.
			     This avoids scrolling the screen, making it  eas-
			     ier  to  read  while  is writing.	This option is
			     ignored if	the terminal has  no  clear-to-end-of-
			     line capability.

	      Prompt user with the message
			     at	 the end of each screenful.  This is useful if
			     is	being used as a	filter in some	setting,  such
			     as	 a  training  class, where many	users might be
			     unsophisticated.

	      Exit immediately after writing the last line of the last file in
	      the
			     argument list

	      Count logical lines, rather than screen lines.
			     That  is, long lines are not folded.  This	option
			     is	recommended if nroff  output  is  being	 piped
			     through  ul, since	the latter can generate	escape
			     sequences.	 These escape sequences	contain	 char-
			     acters  that would	ordinarily occupy screen posi-
			     tions, but	which do not print when	 sent  to  the
			     terminal  as  part	 of  an	escape sequence.  Thus
			     might assume lines	are longer  than  they	really
			     are, and fold lines erroneously.

	      Perform pattern matching in searches without regard to case.

	      Squeeze multiple blank lines from	the output,
			     producing	only one blank line.  Especially help-
			     ful when viewing nroff output, this option	 maxi-
			     mizes  the	 useful	 information  present  on  the
			     screen.

	      Normally,	     handles underlining and bold such as produced  by
			     nroff  in	a manner appropriate to	the particular
			     terminal: if the terminal supports	underlining or
			     has  a highlighting (usually inverse-video) mode,
			     outputs appropriate escape	 sequences  to	enable
			     underlining,  else	 highlighting mode, for	under-
			     lined information in the  source  file.   If  the
			     terminal  supports	 highlighting,	uses that mode
			     information that should be	 printed  in  boldface
			     type.   The option	suppresses this	processing, as
			     do	the "ul" and "os" terminfo flags.

	      Do not display nonprinting characters graphically;  by  default,
	      all
			     non-ASCII	and control characters (except and are
			     displayed visibly in the form  for	 or  for  non-
			     ASCII character

	      Same as not specifying
			     with the exception	of displaying as as and	as

	      Execute the    command  initially	 in  the  command argument for
			     each file examined.  If the command  is  a	 posi-
			     tioning command, such as a	line number or a regu-
			     lar expression search, sets the current  position
			     to	 represent  the	 final results of the command,
			     without writing any  intermediate	lines  of  the
			     file.   If	 the positioning command is unsuccess-
			     ful, the first line in the	file  is  the  current
			     position.

	      Write the	screenful of the file containing the tag named by the
			     tagstring argument.  The specified	tag appears in
			     the current position.  If both  and  options  are
			     specified,	 processes  first;  that  is, the file
			     containing	the tagstring is selected by and  then
			     the command is executed.

	      Set the tabstops every
			     tabs  position.  The  default  value for the tabs
			     argument is 8.

	      Provides optional	extensions to the
			     command.  Currently, the  following  two  options
			     are supported:

				  Prevents	 from	sending	 the  terminal
						 initialization	string	before
						 displaying  the  file.	  This
						 argument also	prevents  from
						 sending  the terminal de-ini-
						 tialization   string	before
						 exiting.

				  Causes	 to  send  the	initialization
						 and	     de-initialization
						 strings. This is the default.

	      Start listing such that the current position is set to
			     linenumber.

	      Start listing such that the current position is set to two lines
	      above
			     the line matching the regular expression pattern.

			     Note: Unlike editors, this	construct  should  NOT
			     end  with	a  If  it  does, the trailing slash is
			     taken as character	in the search pattern.

       The number of lines available per screen	is determined by  the  option,
       if  present or by examining values in the environment.  The actual num-
       ber of lines written is one less	than this number, as the last line  of
       the screen is used to write a user prompt and user input.

       The  number  of	columns	 available per line is determined by examining
       values in the environment.  writes  lines  containing  more  characters
       than  would  fit	 into this number of columns by	breaking the line into
       one more	logical	lines where each of these lines	but the	last  contains
       the number of characters	needed to fill the columns.  The logical lines
       are written independently of each other;	that is, commands affecting  a
       single line affect them separately.

       While determining the number of lines and the number of columns,	if the
       methods described above do not yield  any  number  then	uses  terminfo
       descriptor  files (see term(4)).	 If this also fails then the number of
       lines is	set to 24 and the number of columns to 80.

       When standard output  is	 a  terminal  and  is  not  specified,	treats
       backspace characters and	carriage-return	characters specially.

	      o	 A character, followed first by	a backspace character, then by
		 an underscore (_), causes that	character  to  be  written  as
		 underlined  text,  if	the  terminal supports that. An	under-
		 score,	followed first by  a  backspace	 character,  then  any
		 character, also causes	that character to be written as	under-
		 lined text, if	the terminal supports that.

	      o	 A backspace character	that  appears  between	two  identical
		 printable characters causes the first of those	two characters
		 to be written as emboldened text, if the terminal  type  sup-
		 ports that, and the second to be discarded.  Immediately sub-
		 sequent occurrences of	backspaces/character  pairs  for  that
		 same character	is also	discarded.

	      o	 Other	backspace  character  sequences	is written directly to
		 the terminal, which generally causes the character  preceding
		 the backspace character to be suppressed in the display.

	      o	 A  carriage-return character at the end of a line is ignored,
		 rather	than being written as a	control	character.

       If the standard output is not a terminal	device,	always exits  when  it
       reaches	end-of-file  on	the last file in its argument list. Otherwise,
       for all files but the last, prompts, with an  indication	 that  it  has
       reached	the end	of file, along with the	name of	the next file. For the
       last file specified, or for the standard	input if no file is specified,
       prompts,	indicating end-fo-file,	and accept additional commands.	If the
       next command specifies forward scrolling, will exit. If the  option  is
       specified,  will	 exit  immediately  after writing the last line	of the
       last file.

       uses the	environment variable to	preset any flags desired. The variable
       thus  sets  a  string  containing  flags	 and  arguments, preceded with
       hyphens and blank-character-separated as	on the command line. Any  com-
       mand-line flags or arguments are	processed after	those in the variable,
       as if the command line were as follows:

       For example, to view files using	the mode of operation, the shell  com-
       mand sequence

       or the csh command

       causes all invocations of including invocations by programs such	as man
       and msgs, to use	this mode.  The	command	 sequence  that	 sets  up  the
       environment variable is usually placed in the .profile or .cshrc	file.

       In  the	following  descriptions,  the  current	position refers	to two
       things:

	      o	 the position of the current line on the screen

	      o	 the line number (in the file) of  the	current	 line  on  the
		 screen

       The  line  on  the  screen corresponding	to the current position	is the
       third line on the screen. If this is not	possible (there	are fewer than
       three  lines to display or this is the first page of the	file, or it is
       the last	page of	the file), then	the current  position  is  either  the
       first or	last line on the screen.

       Other  sequences	 that can be typed when	pauses,	and their effects, are
       as follows (i is	an optional integer argument, defaulting to 1):

	      Scroll forward i lines. The default i for	is one screenful;  for
			     and  it is	one line. The entire i lines are writ-
			     ten, even if i is more than the screen  size.  At
			     end-of-file,  causes  to  continue	 with the next
			     file in the list, or exits	if the current file is
			     the last file in the list.

	      Scroll forward i lines, with a default of	one half of the	screen
			     size.  If i is  specified,	 it  becomes  the  new
			     default for subsequent and	commands.

	      Scrolls backward
			     i lines, with a default of	one half of the	screen
			     size. If i	 is  specified,	 it  becomes  the  new
			     default for subsequent and	commands.

	      Scrolls backward
			     i lines, with a default of	one line. The entire i
			     lines are written,	even if	i  is  more  than  the
			     screen size.

	      Display	     i	more lines and sets the	new window (screenful)
			     size to i .

	      Go to line     i in the file, with a default of 1	(beginning  of
			     file).  Scroll  or	rewrite	the screen so that the
			     line is at	the current  position.	If  i  is  not
			     specified,	 then  displays	the first screenful in
			     the file.

	      Go to line     i in the file, with a default of the end  of  the
			     file.  If i is not	specified, scrolls or rewrites
			     screen so that the	last line in the  file	is  at
			     the  bottom  of  the  screen.  If i is specified,
			     scrolls or	rewrites the screen so that  the  line
			     is	at the current position.

	      Skip forward   i	lines, with a default of 1, and	write the next
			     screenful beginning at that  point.  If  i	 would
			     cause  the	 current position to be	such that less
			     than one screenful	would  be  written,  the  last
			     screenful in the file is written.

	      Move forward   i lines, with a default of	one screenful. At end-
			     of-file, will continue with the next file in  the
			     list,  or	exit  if  the current file is the last
			     file in the list.

	      Move backward  i lines, with a default of	one screenful. If i is
			     more than the screen size,	only the final screen-
			     ful will be written.

	      Exit from

	      Write the	name of	the file currently being examined, the	number
	      relative
			     to	 the  total number of files there are to exam-
			     ine, the current line number,  the	 current  byte
			     number,  and  the	total  bytes to	write and what
			     percentage	of the file precedes the current posi-
			     tion. All of these	items reference	the first byte
			     of	the line after the last	line written.

	      Invoke an	editor to edit the current file	 being	examined.  The
	      name of the
			     editor  is	taken from the environment variable or
			     default to	If represents either or	the editor  is
			     invoked with options such that the	current	editor
			     line is the physical line	corresponding  to  the
			     current  position	in  at the time	of the invoca-
			     tion.

			     When the editor exits,  resumes  on  the  current
			     file  by  rewriting  the  screen with the current
			     line as the current position.

	      Display a	description of all the
			     commands.

	      Search forward in	the file for the
			     i-th  line	 containing  the  regular   expression
			     expression.   The	default	 value for i is	1. The
			     search starts at the line following  the  current
			     position.	 If  the  search  is  successful,  the
			     screen is modified	so that	the searched-for  line
			     is	 in  the  current  position.  The null regular
			     expression	repeats	the search using the  previous
			     regular expression. If the	character is included,
			     the lines for searching are  those	 that  do  not
			     contain expression.

			     If	 there	are less than i	occurrences of expres-
			     sion, and the input is a file rather than a pipe,
			     then the position in the file remains unchanged.

			     The  user's erase and kill	characters can be used
			     to	edit the  regular  expression.	 Erasing  back
			     past the first column cancels the search command.

	      Same as	     but  searches  backward  in the file for the i th
			     line containing the  regular  expression  expres-
			     sion.

			     Note:  Unlike  editors,  the construct should NOT
			     end with a	If it  does,  the  trailing  slash  is
			     taken as a	character in the search	pattern.

	      Repeat the previous search for the
			     i-th line (default	1) containing the last expres-
			     sion (or not containing the last  expression,  if
			     the previous search was or

	      Repeat  the  search  for	the opposite direction of the previous
	      search for the
			     i-th line (default	1) containing the last expres-
			     sion

	      (2 apostrophes) Return to	the position from which	the last large
	      movement
			     command was executed ("large movement" is defined
			     as	 any  movement	of  more  than	a screenful of
			     lines). If	no  such  movements  have  been	 made,
			     return to the beginning of	the file.

	      Invoke a shell with
			     command.	The  characters	 and  in  command  are
			     replaced with the current file name and the  pre-
			     vious  shell  command, respectively.  If there is
			     no	current	 file  name,  is  not  expanded.   The
			     sequences and are replaced	by and respectively.

	      Examine a	new file. If the
			     file  argument  is	 not  specified, the "current"
			     file (see the and	commands)  from	 the  list  of
			     files  in	the  command line is re-examined.  The
			     filename is subjected to  the  process  of	 shell
			     word  expansions.	 If  file  is  a (number sign)
			     character,	the previously examined	 file  is  re-
			     examined.

	      Examine the next file. If
			     i is specified, examines the i-th next file spec-
			     ified in the command line.

	      Examine the previous file. If a number
			     i is specified, examines the i-th	previous  file
			     specified in the command line.

	      Go to the	supplied
			     tagstring	and  scroll or rewrite the screen with
			     that line in the current position.

	      Mark the current position	with the specified letter, where
			     letter represents the name	of one of  the	lower-
			     case letters of the portable character set.

	      Return to	the position that was previously marked	with the spec-
	      ified
			     letter, making that line the current position.

	      Refresh the screen.

	      Refresh the screen, discarding any buffered input.

	      Dot. Repeat the previous command.

	      Halt a partial display of	text.
			     stops sending  output,  and  displays  the	 usual
			     prompt.  Unfortunately,  some output is lost as a
			     result.

       The commands take effect	immediately; i.e.,  it	is  not	 necessary  to
       press  Up  to  the time when the	command	character itself is given, the
       line-kill character can be used to cancel the numerical argument	 being
       formed.

       If the standard output is not a teletype, is equivalent to cat(1).

       supports	 the signal, and redraws the screen in response	to window size
       changes.

EXTERNAL INFLUENCES
   Environment Variables
       Overrides the system-selected horizontal	screen size.

       Used by the    command to select	an editor.

       Provides	a default value	for the	 internationalization  variables  that
       are unset
		      or  null.	 If is unset or	null, the default value	of "C"
		      (see lang(5)) is used. If	any of	the  internationaliza-
		      tion  variables contains an invalid setting, will	behave
		      as if all	internationalization variables are set to "C".
		      See environ(5).

       If  set	to  a  non-empty string	value, overrides the values of all the
       other
		      internationalization variables.

       Determines the interpretation of	text as	single and/or
		      multi-byte characters, the classification	of  characters
		      as  printable,  and  the characters matched by character
		      class expressions	in regular expressions.

       Determines the locale that should be used to affect the format and con-
       tents
		      of  diagnostic  messages	written	 to standard error and
		      informative messages written to standard output.

       Determines the location of message catalogues for the processing	of

       Overrides the system-selected vertical screen size, used	as the number
		      of lines in a screenful.	The  option  takes  precedence
		      over the variable	for determining	the number of lines in
		      a	screenful.

       Determines a string containing options, preceded	with hyphens
		      and blank-character-separated as on  the	command	 line.
		      Any  command-line	 options  are processed	after those in
		      the variable. The	variable takes precedence over the and
		      variables	 for  determining  the	number	of  lines in a
		      screenful.

       Determines the name of the terminal type.

   International Code Set Support
       Single- and multi-byte character	code sets are supported.

APPLICATION USAGE
       When the	standard output	is not a terminal, none	of the	filter-modifi-
       cation  options is effective. This is based on historical practice. For
       example,	a typical  implementation  of  pipes  its  output  through  to
       squeeze	excess	white  space for terminal users. When is piped to how-
       ever, it	is undesirable for this	squeezing to happen.

EXAMPLES
       To view a simple	file, use:

       To preview nroff	output,	use a command resembling:

       If the file contains tables, use:

       To display file in a fifteen line-window	and convert multiple  adjacent
       blank lines into	a single blank line:

       To examine each file with its last screenful:

       To  examine  each  file	starting with line 100 in the current position
       (third line, so line 98 is the first line written):

       To examine the file that	contains the tagstring tag with	line 30	in the
       current position:

WARNINGS
       Standard	 error,	 file  descriptor 2, is	normally used for input	during
       interactive use and should not be redirected (see Input/Output  section
       in the manpage of the shell in use).

FILES
       compiled	terminal capability data base

AUTHOR
       was  developed  by  Mark	 Nudleman, University of California, Berkeley,
       OSF, and	HP.

SEE ALSO
       csh(1),	man(1),	 pg(1),	 sh(1),	 term(4),   terminfo(4),   environ(5),
       lang(5),	regexp(5).

STANDARDS CONFORMANCE
								       more(1)

NAME | SYNOPSIS | DESCRIPTION | EXTERNAL INFLUENCES | APPLICATION USAGE | EXAMPLES | WARNINGS | FILES | AUTHOR | SEE ALSO | STANDARDS CONFORMANCE

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=more&sektion=1&manpath=HP-UX+11.22>

home | help