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

FreeBSD Manual Pages

  
 
  

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

NAME
       gate - gather text input	for PicoSpan or	Yapp with word-wrapping

SYNOPSIS
       gate [--_option_...]  file

DESCRIPTION
       Gate is a word-wrapping input gatherer designed to be used with the Pi-
       coSpan or Yapp conferencing programs. (by Marcus	Watts and Dave	Thaler
       respectively).	It behaves very	much like the built-in text gatherers,
       with the	exception that it automatically	word-wraps as you  type,  pro-
       vides  integrated  spell	 checking,  and	has a few other	minor improve-
       ments.

       Though it is possible to	run gate directly (and it might	have some  ap-
       plication  in shell scripts that	want to	do nicer text gathering), nor-
       mally you would allow the conferencing system to	run  it	 for  you,  by
       putting the following PicoSpan (or Yapp)	commands in your .cfonce file:

	      set edalways
	      define editor "gate"

       The latter command should give the full path of the gate	command, if it
       is not in your path.

       Gate runs in cbreak mode, but it	carefully simulates all	the usual unix
       line-editting  keys, so whatever	backspace, word-erase, line-kill, end-
       of-file,	and reprint keys you have defined with stty(1)	will  work  as
       usual (even with	tabs in	your text).

       Gate allows you to backspace back onto previous lines (so long as those
       lines are not longer than your screen width).  For more elaborate edit-
       ing us the :edit	or :/ commands.

       In  addition  to	the standard keys, typing control-L will redisplay the
       entire body of text entered so far.

       Text entry is normally terminated by either a  dot  (.)	typed  in  the
       first column, or	the usual unix end-of-file character.

COLON COMMANDS
       The  following  special commands	can be entered at the beginning	of any
       line.  All of them can be abbreviated.

       :clear	 Empty out the text buffer, discarding everything  entered  so
		 far, and restart text entry with a clean slate.

       :edit	 Start	up  the	 editor	on the text.  The environment variable
		 EDITOR	selects	which editor to	use.  When you exit  the  edi-
		 tor,  text  entry will	be continued.  A colon alone on	a line
		 will also start the editor.

       :empty	 This is the same as the :clear	command.

       :exit [!] This is the same as the :quit command.

       :help	 Print a short help message.

       :quit [!] Terminate text	entry, and discard the response	without	enter-
		 ing  it.  Normally, it	will ask for confirmation that you re-
		 ally want to do this.	If you give a "!" as an	 argument,  it
		 will skip the confirmation request.

       :ok	 Terminate  text  entry,  and ask if you want to enter the re-
		 sponse	or not.

       :read [-s] <file>
		 Append	the named file to the text you have  entered  so  far.
		 Normally  unprintable	characters will	be stripped out	of the
		 file as it is read. If	the -s flag is	given,	they  will  be
		 left in.

       :set [<option>...]
		 Without  arguments, this command prints the current values of
		 the various settable options  for  gate.   If	arguments  are
		 given,	 those	options	 are  set. See below for a list	of op-
		 tions.

       :spell	 Run a spell check on the current text.	  You  will  be	 shown
		 each  misspelled word in context, and be asked	for a replace-
		 ment.	If instead of entering a replacement  you  simply  hit
		 return, all instances of the word will	be left	unchanged.  If
		 you type a + (plus) then all instances	of the	word  will  be
		 left  unchanged,  and it will be added	into your private dic-
		 tionary so it will be recognized as being  correctly  spelled
		 in  future spell checks.  If you type a (backslash), then the
		 spell check will be cancelled.	 A ?  (question	 mark)	prints
		 help.

       :visual	 This is the same as the :edit command.

       :version	 Print out the current gate version number.

       :write <file>
		 Save  a  copy	of  the	current	text buffer in the named file.
		 :edit command.

       :!<cmd>	 Do a shell escape to execute a	unix command. The colon	may be
		 omitted.

       :|<cmd>	 Filter	 the  current text through the given unix command. The
		 command will be fed the current text on standard  input,  and
		 whatever appears on standard output will replace the contents
		 of the	text file. This	is normally used to pipe through  for-
		 matting programs.

       :/<pattern>/<replacement>/
		 Each  occurance  of  the given	pattern	in the text entered so
		 far will be replaced by the given replacement.	 As each occu-
		 rance	is found, you asked to confirm the substitution.  Typ-
		 ing "y" does the substitution,	typing "n" skips the substitu-
		 tion,	typing	"a" does the substition	and all	others without
		 further prompting, and	typing "q" stops the scan  immediately
		 with  no further substitutions.  Both the pattern and the re-
		 placement may include the characters "\n" which represents  a
		 newline  character.  This makes it possible to	join and break
		 lines.	A "\\" indicates a backslash character,	and a "\/" in-
		 dicates a slash.  The terminating slash on the	command	may be
		 omitted.  Note	that this is intended only  for	 simple	 edit-
		 ting.	For  complex  editting tasks, use the :edit command to
		 start up an editor.

       :substitute /<pattern>/<replacement>/
		 Equivalent to the ":/"	command.

OPTIONS
       Options may be set either on the	command	line (with a  ``--''  prefix),
       by the :set command described above, or by putting them in the GATEOPTS
       environment variable.  For example, from	the csh(1) shell you could do:
	      setenv GATEOPTS "nonovice	maxcol=70"
       or from bbs(1) you could	do:
	      define GATEOPTS 256 "nonovice maxcol=70"

       Options currently supported are listed below.  Default settings are in-
       stallation dependent.

       [no]askok If  askok  is set, gate always	asks if	it is OK to enter this
		 response.  Otherwise it only asks if you do  a	 :ok  command.
		 Askok	is (more or less) implied by the spell or askspell op-
		 tions.

       [no]backwrap
		 If the	backwrap is turned on, backspacing in the first	column
		 will move you to the end of the previous line.	 If the	termi-
		 nal supports it, and the previous line	of the	text  file  is
		 the previous line of the screen, gate will move the cursor up
		 into that line.  Otherwise, however, it  reprints  the	 line.
		 This  behavior	is a bit weird and confusing to	people who ex-
		 pect a	full visual editor, it,	so it may be good  to  disable
		 this  option for beginners.  Note that	backwrap will not work
		 if the	previous line is more than maxcol columns long.

       cmdchar=<char>
		 Cmdchar specifies the character that is used at the  begining
		 of  an	 input line to indicate	that the rest of the line is a
		 command.  The default is a colon (:).

       hotcol=<int>
		 Hotcol	specifies the last column in which spaces may  be  en-
		 tered.	 If  you  type a space beyond this column, you will be
		 instantly moved to the	next line.  The	length of your	prompt
		 is included in	your line length.  Normally hotcol is set just
		 slightly smaller than maxcol.	If hotcol is larger than  max-
		 col, it has no	effect.

       maxcol=<int>
		 Maxcol	 specifies  the	last column in which any character may
		 be entered.  If you attempt to	type  a	 word  extending  past
		 this column, it will be moved onto the	next line.  The	length
		 of your prompt	is included in your line length.  Normally  it
		 should	 be no larger than 79, since typing in the 80th	column
		 confuses some terminals.  It can be set to  a	value  greater
		 than screen width of your terminal with the :set command, but
		 not with the GATEOPTS.

       [no]novice
		 If novice is set, gate	will print additional help messages if
		 you  commit  any of several common novice errors, like	typing
		 an input line with just the work "quit" on it.

       outdent=<int>
		 When a	response is displayed by PicoSpan or Yapp,  each  line
		 has  a	space prepended.  This will indent most	lines one col-
		 umn, but lines	starting with a	tab will  be  unchanged.   The
		 outdent  option  allows  gate	to adjust the positions	of its
		 tabstops to correct for this.	Effectively, it	 does  tabbing
		 as  if	 the screen started outdent columns to the left	of the
		 end of	the prompt.

       prompt=<string>
		 Normally gate prints a	> prompt for each  line.   The	prompt
		 can  be  set  to  any string, including a null	string.	 It is
		 slightly preferable to	use a prompt whose length is equal  to
		 outdent, since	this gives a more WYSIWYG display, but this is
		 by no means necessary.

       [no]secure
		 If secure is set, the buffer file being editted will be  kept
		 depermitted  as much as possible, to keep people from reading
		 your text before you are finished with	 it.  If  nosecure  is
		 set, the buffer file will normally be readable	to others.

       [no|ask]spell
		 If  spell  is	set,  the  spellchecker	 will automatically be
		 started when you exit.	 If askspell is	set, you will be asked
		 if you	want to	check spelling when you	exit.

AUTHOR
       Jan Wolter

SEE ALSO
       bbs(1), vi(1), pico(1), stty(1),	spell(1)

				  6 June 1995			       GATE(1)

NAME | SYNOPSIS | DESCRIPTION | COLON COMMANDS | OPTIONS | AUTHOR | SEE ALSO

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=gate&sektion=1&manpath=FreeBSD+13.0-RELEASE+and+Ports>

home | help