home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / comp / unix / shell / 3768 < prev    next >
Encoding:
Text File  |  1992-09-02  |  1.0 KB  |  42 lines

  1. Newsgroups: comp.unix.shell
  2. Path: sparky!uunet!walter!fork!snk
  3. From: snk@fork.bae.bellcore.com (Samuel Kamens)
  4. Subject: Re: Need rot13 script
  5. Message-ID: <1992Sep2.151901.12116@walter.bellcore.com>
  6. Sender: news@walter.bellcore.com
  7. Nntp-Posting-Host: fork.bae.bellcore.com
  8. Reply-To: snk@bae.bellcore.com
  9. Organization: Bell Communications Research
  10. References:  <36915@uflorida.cis.ufl.edu>
  11. Distribution: na
  12. Date: Wed, 2 Sep 92 15:19:01 GMT
  13. Lines: 27
  14.  
  15. In article <36915@uflorida.cis.ufl.edu>, kcw@reef.cis.ufl.edu (Ken Whedbee) writes:
  16. > Hi -
  17. > Can somebody send me a simple shell script that can convert a
  18. > text file back and forth between rot13 ?
  19. > Many thanx!
  20.  
  21. Read the man page for the "tr" command.
  22.  
  23. Here's the command to do what you want:
  24.  
  25. tr [a-m][A-M][n-z][N-Z] [n-z][N-Z][a-m][A-M] < inputfile > outputfile
  26.  
  27. Bear in mind that your tr may differ a bit -- this works on my Sparc
  28. IPX, SunOS 4.1.1.
  29.  
  30. Sam
  31.  
  32.  
  33. -- 
  34. Sam Kamens                    Bell Communications Research
  35. snk@bae.bellcore.com                Phone: (908) 699-7509
  36. 444 Hoes Lane  Room RRC 1D-210
  37. Piscataway, NJ 08854
  38.