home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format 61 / af061sub.adf / SmileyV3.lha / smiley.doc < prev   
Text File  |  1994-05-16  |  2KB  |  78 lines

  1. NAME
  2.      smiley - print or explain smileys
  3.  
  4. SYNOPSIS
  5.      smiley [-V] [-e] [-l] [-f] [_s_m_i_l_e_y...]
  6.  
  7. DESCRIPTION
  8.      _S_m_i_l_e_y is a program for smiley junkies who like to have all
  9.      the smileys at their fingertips.
  10.  
  11.      The options have the following meaning:
  12.  
  13.      -V   Print the version of the program and the number of
  14.           faces and definitions.
  15.  
  16.      -e   Explain the face found in the environment variable SMI-
  17.           LEY.
  18.  
  19.      -l   Print a listing of all the known smileys, with explana-
  20.           tions.
  21.  
  22.      -f   Print a random smiley, face only.
  23.  
  24.      _s_m_i_l_e_y
  25.           Explain the given smiley.
  26.  
  27.      When invoked with no arguments, _s_m_i_l_e_y prints a random smi-
  28.      ley with an explanation.
  29.  
  30. EXAMPLE
  31.      Here are some _k_s_h(1) functions that put a smiley into your
  32.      prompt.
  33.  
  34.      ps1sed()
  35.           Transform the standard input so that it will display
  36.           properly when it is made part of PS1 in _k_s_h.  (That is,
  37.           quote  ! $ \  if they appear.) These are the transfor-
  38.           mations:
  39.  
  40.                !    ->   !!
  41.                $    ->   \$
  42.                \    ->   \\
  43.  
  44.           Note that a  !  must be doubled instead of quoted with
  45.            \  in order to display.
  46.  
  47.           ps1sed()
  48.           {
  49.                sed 's/!/&&/g
  50.                     s/[$\\]/\\&/g'
  51.           }
  52.  
  53.      ps1()
  54.           Put a new smiley into PS1.  Use _p_s_1_s_e_d to make sure any
  55.           characters in the smiley that are special to the shell
  56.           are quoted appropriately.
  57.  
  58.           ps1()
  59.           {
  60.                export SMILEY="`smiley -f`"
  61.                PS1=`print -r - "$SMILEY" | ps1sed`" "
  62.           }
  63.  
  64. CAVEATS
  65.      The list of smileys is the personal collection of the
  66.      author, so there are bound to be some missing.
  67.  
  68.      Multiline smileys and the ``invisible smiley'' are absent
  69.      from _s_m_i_l_e_y because the author does not want a multiline or
  70.      invisible prompt.
  71.  
  72. AUTHOR
  73.      DaviD W. Sanderson  (dws@cs.wisc.edu)
  74.  
  75. COPYRIGHT
  76.  
  77.      (C) Copyright 1991 by DaviD W. Sanderson
  78.