glenda.party
term% ls -F
term% cat index.txt
MOTHRA(1)                   General Commands Manual                  MOTHRA(1)



NAME
       mothra - retrieve and display World-Wide Web files

SYNOPSIS
       mothra [ -va ] [ -m mtpt ] [ url ]

DESCRIPTION
       Mothra  uses webfs(4) to retrieve and display files from the World-Wide
       Web, by name or through hypertext links.  Web names, called URLs,  have
       a peculiar syntax:

              http://9front.org/
              https://code.9front.org/plan9front/
              http://cat-v.org/

       The  part  up  to the first colon gives the protocol for retrieving the
       file.  http:, Hyper-Text Transfer Protocol, is the usual way of access‐
       ing web files.

       //  begins  the  Internet address of the server where the file resides.
       The address may contain a colon and a TCP port number, which  overrides
       the  default port number for the service.  Next comes a file name.  Fi‐
       nally, the file name may be followed by # and a string giving  a  label
       within the file where the display should begin.

       Mothra starts with the url given on the command line, defaulting to the
       environment variable $url.

       There are a number of options:

       -a     Alt display. Starts in alt display mode, see menu commands table
              below.

       -m     Specify  the  webfs(4)  mountpoint with -m mtpt.  The default is
              /mnt/web.

       -v     Verbose mode. Causes HTML errors to be printed on  file-descrip‐
              tor 2.

       The  display  contains  the last message from mothra, a box where typed
       commands appear, a scrollable list of previously visited files, the ti‐
       tle and URL of the current file, and the scrollable text of the current
       file.

       Button 1 selects and displays a file, either from the  list  of  previ‐
       ously  visited  pages or from a link (indicated by underlined text or a
       boxed image) in the current file.  Button 2 shows the URL  of  a  file,
       but  does  not retrieve or display it.  Button 3 pops up a menu of com‐
       mands:

       alt display
              Collapse or expand the  navigation  boxes  at  the  top  of  the
              browser window.

       moth mode
              Enter moth mode and switch to the moth cursor. If the HREF of an
              image link is different from the URL of the image itself, a link
              to  the  HREF  will  be  printed on the right side of the image.
              Clicking an image or link with mouse button 1 prompts  the  user
              to  save  a copy of the file in the current directory.  Clicking
              mouse button 2 sets the target as the current URL.  Clicking the
              moth mode menu option again exits moth mode.

       snarf  Copy  the current entry text or selected page text to snarf buf‐
              fer.  If nothing is selected, the current URL is copied.

       paste  Paste the snarf buffer to the current text entry.

       search Search for a regular expression in the current page.

       save hit
              Save the current URL to the hit list.

       hit list
              Retrieve and display the hit list.

       exit   Ask for confirmation and quit.

       The typed commands are:

       a      Toggle alt display.

       g url  Go to the page with the given URL.

       j n    Jump to page n from the list of previously viewed pages.

       k      Kill images on the current page.

       m      Enter or exit moth mode.

       r      Reload the current page.

       s file Save the current page in the given file.

       W file Capture a screenshot of the entire browser window in  the  given
              file.

       w file Capture a screenshot of the content area in the given file.

       q      Quit.

       When mothra retrieves a direct link to a file that is not an HTML docu‐
       ment (for example a GIF or JPEG image), it will start up an appropriate
       viewer, for example page (see page(1)) for most image files.

FILES
       $home/lib/mothra/hit.html the hit list

SOURCE
       /sys/src/cmd/mothra

SEE ALSO
       webfs(4)

BUGS
       Files  are saved in the form received, not in the form suggested by the
       name in an s command. A directory index saved from  moth  mode  may  be
       written  in  the local directory as a file named index.  Sanitizing re‐
       mote file names for the local file system is imperfect.

       Mothra is distributed in a preliminary state;  it  has  more  than  its
       share  of bugs. Note that mothra, like the other Guardian Monsters, has
       no particular concern for humanity.

HISTORY
       Mothra first appeared in Plan 9 from Bell Labs  (1995).  It  was  later
       modified for inclusion in 9front (September, 2011).



                                                                     MOTHRA(1)