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

  
 
  

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

NAME
     porch, rporch -- Utility to orchestrate command line tools

SYNOPSIS
     porch [-f scriptfile] [command [argument ..]]
     porch [-h]

     rporch [-e rsh] [-f scriptfile] [host]

DESCRIPTION
     The  porch  utility  allows  scripted  interactions with other command line
     tools.

     All uses of porch follow a specific pattern: spawn  a  command,  optionally
     write  to	its stdin, check for patterns in its stdout.  The last two steps
     may be interleaved in interesting ways based on program behavior and inter-
     action.  When porch spawns a command, it sets up a new pts(4) and	disables
     input  echo  on  it.   The command is not executed immediately, but instead
     waits for a release from the user script before processing.  This	is  done
     so that the scriptfile may queue up some input to the program before it be-
     gins execution.  See orch(5) for more detail on porch scripts.

     The following options are available for both porch and rporch:

     -f scriptfile
	     Uses the named scriptfile as the script to execute.  Specifying "-"
	     directs porch to read the script from stdin, and is the default be-
	     havior.

     -h      Show a usage statement.

     The following options are available for rporch only:

     -e rsh  Execute the specified rsh program when spawning a command.

     If  a  command  is specified, then porch will spawn it before executing the
     specified scriptfile.  Execution will still be stalled until  released,  as
     described above.

     The  rporch program is used to execute the scriptfile against programs on a
     remote host.  The script is still primarily run on the executing host,  but
     any  spawned  commands  will be executed via the remote shell specified, in
     order of preference, by either the -e argument or the PORCH_RSH environment
     variable.	If neither of these are set, "ssh" will be used.  The  specified
     rsh  string  will be subjected to word-splitting, and some naive quote han-
     dling will be employed.

ENVIRONMENT
     PORCH_RSH
	     The remote shell progran to use for rporch connections.

EXIT STATUS
     The porch utility exits 0 on success, and >0 if an error occurs.  A match()
     block failing is considered an error, unless it is within	a  one()  block.
     All blocks in a one() block must fail to be considered an error.

SEE ALSO
     expect(1), pts(4), orch(5)

AUTHORS
     porch  was  written by Kyle Evans <kevans@FreeBSD.org> for the express pur-
     pose of testing tty(4) behavior.

FreeBSD ports 15.quarterly	December 5, 2024			PORCH(1)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=porch&sektion=1&manpath=FreeBSD+Ports+15.1.quarterly>

home | help