old-www/LDP/LG/issue01to08/lg_issue8.html

1978 lines
67 KiB
HTML

<HTML>
<!-- HTML HEAD ========================================================== -->
<HEAD><TITLE>Linux Gazette Issue No. 8 </TITLE></HEAD>
<!-- HTML BODY ========================================================== -->
<BODY>
<H1><IMG ALIGN=MIDDLE SRC="../gx/lg_logo.gif"> Issue No. 8</H1>
<H2>A Member of the Linux Documentation Project</H2>
<H4>&quot;The Linux Gazette...<I>making Linux just a little more fun...!</I>
&quot;</H4>
<H5>Copyright (c) 1996 John M. Fisk <I>fiskjm@ctrvax.vanderbilt.edu</I><BR><BR>
The LINUX GAZETTE is a member of the LINUX DOCUMENTATION PROJECT.<BR>
For information regarding copying and distribution of this material see the
<A HREF="./copying.html">COPYING</A> document.<BR></H5>
<HR>
<!-- ===================================================================== -->
<!-- TABLE OF CONTENTS =================================================== -->
<H2><A NAME="toc">Table of Contents</A></H2>
<H3>Topics in this issue include:</H3>
<UL>
<LI><A HREF="#mail">Salutations and the MailBag</A>
<LI><A HREF="#tips">More 2 Cent Tips...</A>
<LI><A HREF="#bardj">PPPD Tips -n- Tricks, by Baard Johannessen</A>
<LI><A HREF="#gcapell">The <I>Wily</I> Text Editor, by Gary Capell</A>
<LI><A HREF="#jphilbrook">Monitoring a Link with SNMP, by Jason Philbrook</A>
<LI><A HREF="#ntjirkalli">Using JAVA and Netscape 2+, by Nic Tjirkalli</A>
<LI><A HREF="#ecame">Web Surfer!, by Ed Cameron</A>
<LI><A HREF="#layers">TkDesk, FTE, Process Meters, html-helper-mode, and
a Whole Lot More!, by Larry Ayers</A>
<LI><A HREF="#gtaylor">Shell Programming, by Geoff Taylor</A>
<LI><A HREF="#jwessling">The Utility Room, by Jens Wessling</A>
<LI><A HREF="#articles">A Collection of Articles Including:</A>
<UL>
<LI><A HREF="./articles.html#awk">An Introduction to AWK, by Cheng Hian Goh</A>
<LI><A HREF="./articles.html#ansi">Cheap ANSI Color!, by Jim Valentine</A>
<LI><A HREF="./articles.html#dired">DIRED: Distant Relative of GNU 'ls', by Grant B.
Gustafson</A>
<LI><A HREF="./articles.html#rm">Securing your RM!, by Christophe Blaess</A>
<LI><A HREF="./articles.html#tar">TAR'ing over the Net, by Mark A. Bentley</A>
<LI><A HREF="./articles.html#tcsh">Taking Full Advantage of TCSH - precmd, by Ryan</A>
<LI><A HREF="./articles.html#xdm">Customizing Logins with XDM, by Yann Le Fablec</A>
<LI><A HREF="./articles.html#zlister">Announcing ZLISTER, by Joe Wulf</A>
</UL>
<LI><A HREF="#upgrade">Kernel 2.0 Upgrade, by John M. Fisk</A>
<LI><A HREF="#colophon">Colophon</A>
</UL>
<P>
<HR>
<!-- ===================================================================== -->
<!-- NEWS FLASH SECTION ================================================== -->
<H2><IMG ALIGN=BOTTOM SRC="./gx/news.gif"><I>News Flash!</I>
<IMG ALIGN=BOTTOM SRC="./gx/news_mirror.gif"></H2>
<P>
<H3><IMG ALIGN=BOTTOM SRC="./gx/info.gif">Linux Gazette coming under New
Management!</H3>
Yup, it's true! As of the next LG issue the Linux Gazette will officially
come under the auspices of the <A HREF="http://www.ssc.com/">Linux Journal
</A>. The 'ol Linux Gazette has grown over the past year -- this is
actually its <B>First Birthday</B> this month -- and it is probably
fitting that after a year it's ready to come under the watch care of the
folks at Linux Journal. <B>Phil Hughes</B> has very graciously offered to
take over the day-to-day management of the Linux Gazette while continuing
its tradition as a free and freely available WWW publication.
<P>
For details of the transition, please head on down to the
&quot;Welcome&quot; section below and read all about it. :-)
<P>
<H3><IMG ALIGN=BOTTOM SRC="./gx/info.gif">Did you know that RedHat had a
Desktop Contest?</H3>
Yup, the folks at <A HREF="http://www.redhat.com">RedHat Software,
Inc.</A>, in conjunction with the folks at Digital Equipment Corp., have
just finished the judging in an <B>X Window Desktop Design Contest</B>.
The lucky winner walked home with a shiny new <B>DEC Alpha</B> running --
what else...? :-) -- RedHat Linux.
<P>
Stop by their Web site and have a look at what's going on there! Also,
for those of you running a RedHat system and who haven't upgraded to the
new 2.0 kernel... Now's your chance!! There are handy online
instructions available outlining which RPM's you'll need to pick up and
how to go about doing the upgrade.
<P>
<H3><IMG ALIGN=BOTTOM SRC="./gx/info.gif">Caldera has purchase DR-DOS and is
suing Microsoft Corp.!!</H3>
<P>
This isn't a joke and it's not a typo -- Caldera is going after M$.
<P>
On the 24th of July (I believe that date is correct)
<A HREF="http://www.caldera.com">Caldera Corporation</A> filed suit
against Microsoft. The details are available at their web site and
include a press release and details of the suit filed against Microsoft.
<P>
You need to read this thing.
<P>
As most of you know, Microsoft just finished a court battle with the
U.S. Dept. of Justice over issues of anti-trust business practices. It'll
be interesting to see how this current suit proceeds.
<P>
<H3><IMG ALIGN=BOTTOM SRC="./gx/info.gif">Caldera Open Linux seeking POSIX and
FIPS Certification for the Linux OS!</H3>
<P>
I recently received a message from <A HREF="mailto: ian@lasermoon.co.uk">
Ian at Lasermoon</A> regarding the proposed development of a <B>Caldera
Open Linux</B> Group that would, as its primary goal, seek POSIX and FIPS
(Federal Information Processing Standard from the National Institute of
Standards, a U.S. Government Agency) certification for the Linux OS.
<P>
Here's a copy of the message Ian sent:
<BLOCKQUOTE>
<P>
Hi,
<P>
Appended is the text of an announcement that is to be sent to the various
mail lists, HowTo developers and News.
<P>
I would be *more* than happy to write an article about this development
for the Gazette if you would be interested.
<P>
If we can assist your efforts in any way (mirroring, services etc etc)
please let me know.
<P>
Keep up the Good Work!
<P>
Cheers,
<P>
----------------------------------
<P>
Hello!
<P>
Appended is the text of a forthcoming announcement about Open Linux - a
project to push Linux through XPG4-95 and UNIX-95 branding. We are gathering
opinion from the main Linux developers (such as yourself) *before* it is
released to various News Groups and mailing lists.
<P>
If you feel that you could contribute to this effort, or that what we
are doing could contribute to your work, please let us know. This is the
start of a huge collaborative effort which is widely seen as the way
forward for UNIX.
<P>
Open, GPL'ed Development.<BR>
-------------------------<BR>
This is an Open Development which will result in a Branded UNIX which
will be freely distributed on the Internet in source and binary forms.
We would welcome constructive comments about this development.
<P>
If you would like to contribute to this project, we would very much like
to hear from you. Please contact Ian Nandhra (ian@caldera.com) for more
details.
<P>
This is a real opportunity to change and re-define the UNIX industry.
<P>
Enjoy!
<P>
=========================
<P>
Caldera is looking for people who want to enhance the Linux
operating system and surrounding utilities so that they are
comformant with X/Open specifications. We feel this effort
provides a tremendous opportunity to help Linux grow beyond the
status of &quot;Unix Clone&quot; to full comformance with
branded UNIX. In short, Linux distributions will be able to
carry the UNIX brand. This will benefit all of us as it will
attract more ISVs and corporate customers, thus giving us all
more application choices and a broader user base of Linux
technologies.
<P>
Caldera's open development model for Caldera Open Linux:
<UL>
<LI> eliminates duplicate development paths
<LI> removes the need for multiple copies of expensive X/Open test
suites
<LI> provides GPL source that is comformant with X/Open specifications.
<P>
Note: downloaded binaries and source will not carry the X/Open
brand for UNIX 95 or XPG Base 95. People wanting to commercially
redistribute the certified and branded kernel will be able to
purchase a licence to do so from Caldera or obtain the test
suites and branding directly from the Open Group.
</UL>
<P>
Caldera respects and will protect the intellectual properties of The Open
Group, including the official X/Open branding test suites that Caldera
recently acquired from Lasermoon of Wickham, England. Caldera will provide
specs for specific technologies needed to complete the certification
and branding program, partnering with others on the Internet to enhance
Linux with POSIX and XPG4 capabilities.
<P>
Engineers and others wishing to work with Caldera in creating an X/Open
Branded Linux operating system should contact Caldera via email to Ian
Nandhra (ian@caldera.com).
<P>
For additional information, visit Caldera's web site
(http://www.caldera.com/) or contact Caldera in the United States at
(801) 229-1675.
<P>
For additional information about The Open Group and the X/Open brand,
contact Robert Noyes in the United States at (415) 323-7992 x 231 or
via email at (rnoyes@xopen.org).
<P>
Note: On May 23, 1996, at the Linux Kongress in Berlin, Germany,
Caldera announced its plans to obtain POSIX and FIPS Certifications and
the X/Open brand for UNIX 95 and XPG4 BASE 95 for the Linux operating
system kernel. A complete news release on the topic can be viewed from
Caldera's home page at http://www.caldera.com/whatsnew/open_linux.html.
<P>
Background: Caldera is leveraging efforts originally pioneered by
Lasermoon of Wickham, England, (http://www.lasermoon.co.uk). In May, 1995,
Lasermoon gained membership in The Open Group (the leading consortium
for the advancement of open systems) and purchased the only existing
test suites for taking the Linux kernel through the X/Open branding
process. Caldera now plans to add resources to this project and manage
a cooperative effort among the Linux community, avoiding unnecessary
duplication of efforts in the certification and branding of Linux as a
full UNIX environment.
<PRE>
--
Ian Nandhra ian@caldera.com
Caldera Inc. 633 South, 550 East,
Provo, Utah, USA. 84606
Voice : 801 229 1675 Fax : 801 229 1579 http://www.caldera.com
</PRE>
</BLOCKQUOTE>
<HR>
<!-- ===================================================================== -->
<!-- WELCOME MESSAGE ===================================================== -->
<H2>Welcome to Issue #8 of the <B>Linux Gazette !</B></H2>
<P>
We're One Year Old this month!
<P>
Yup, pretty amazing that the Linux Gazette is now a year old after starting
life as a project to learn a bit of HTML development in my spare time. Funny
how things turn out :-)
<P>
I'd like to stop at this point and offer some very heartfelt thanks to the
myriad of folks who have graciously offered help and support for the Linux
Gazette along the way. To the guys at <A HREF="http://www.tenn.com">Tennessee
CommerceNet</A> where the LG had its inception; <A HREF="http://www.redhat.com">
RedHat Software Inc.</A> who took the initial interest in the Gazette and
provided much needed WWW and FTP support; <A HREF="http://www.ssc.com">SSC and
the folks at Linux Journal</A> who offered support and encouragement as the
Linux Gazette continued to grow; to <A HREF="http://www.pht.com">Pacific
HiTech</A> for putting the Linux Gazette on its monthly <B>Mo' Linux CD</B>...
THANKS!!
<P>
Without all your help the LG wouldn't be possible.
<P>
Also, heartfelt kudos to the scores of folks who have written notes of
encouragement, suggested ideas, offered comments and criticisms, wrote
articles, provided WWW and FTP mirror sites, and took the time to drop a note
just to chat about the coolest OS on the face of the earth!
<P>
Thanks!
<P>
And to all the guys who've become regulars around the 'ol Gazette -- Ed
Cameron, Larry Ayers, Jesper Pedersen, Brian Freeze, Jens Wessling, &amp; and
MANY MORE...
<P>
Thanks Guys!!
<P>
And finally, I want to offer a very special note of thanks to <B>Phil
Hughes</B> at the Linux Journal. Phil is one of those infectiously nice guys
that starts a casual conversation with you and after 2 hours, you're talking
and laughing like life-long buddies. He's a great guy and I'm absolutely
delighted that he and the folks at the Linux Journal have been willing to take
over the care and feeding of the Linux Gazette.
<P>
Here's a quick note from <B>Phil Hughes</B> about the upcoming transition:
<BLOCKQUOTE>
<P> Here at SSC we have always felt that the <I>Linux Gazette</I> filled
a niche that <A HREF="http://www.ssc.com/lj"> <I>Linux Journal</I></A>
could not. Being on-line it could be more timely and address topics
that would not be cost-effective in print media.
<P> When John Fisk mentioned that he might not be able to continue
publication of the Gazette because of the time committment involved, I
worked with him to make it possible for it to continue as a timely,
vendor-independent source of information on Linux.
<P> Our plans are to continue the electronic version of the Gazette (its
home is <A HREF="http://www.ssc.com/lg/"> http://www.ssc.com/lg/</A>)
plus we will offer a <I>Linux Gazette</I> section in <I>Linux
Journal</I> which will include the items we feel are of the most
interest to LJ readers.
<P> Marjorie Richardson will take over the position of Editor of the
Gazette. Her expericence in programming, working with Unix, and
technical editing for <I>Linux Journal</I> and other SSC products gives
her the needed background and experience to handle this assignment. If
you have suggestions for the Gazette or want to make a contribution to
an upcoming issue, she can be reached at
<A HREF="mailto:gazette@ssc.com"> gazette@ssc.com</A>.
<P>
Phil Hughes<BR>
<A HREF="mailto:phil@ssc.com">phil@ssc.com</A>
</BLOCKQUOTE>
<P>
You see, I've enjoyed working on the Linux Gazette like few things in life.
This has been a HUGE amount of fun and it's brought me into contact with some
of the most delightful folks in the Linux Community. It's also shown to me
the tremendous spirit of community that exists among the literally world-wide
group of Linux users. I've had mail from all over the US, Canada, Mexico,
South America, the UK, Germany, Spain, Sweden, Finland, Czechoslovakia,
Greece, Austria, Africa, the Orient, Australia, and Antarctica!
<P>
Antarctica!!
<P>
For crying out loud! There's some poor frozen guy sitting on the
coldest ice slab on the face of this planet tinkering around with
Linux!!
<P>
Seriously Way Too Cool...!!
<P>
Tell me that Bill G. gets mail from Antarctica telling him what a great OS he
has... ;-)
<P>
Anyway, it's been HUGE.
<P>
And that brings me to why I decided to turn the Gazette over to the folks at
Linux Journal.
<P>
While the LG has been a huge amount of fun this past year, it's also been a
HUGE amount of work. I figure that each issue requires in the neighborhood of
20 to 30 hours of editing, proofreading, writing, reading, and tinkering to
get ready for release -- and that DOES NOT include the piles of email that
come in and the replies that need to be handled. Nor does it include the
hours spent pouring through Usenet postings and tracking down ideas and
suggestions there.
<P>
In the last issue of the LG I put out a plea for help and I was overwhelmed by
the responce. Still, as I tried to get the LG organized and restructured it
became more and more clear that it was starting to get out of hand. Things
here in our household have been getting pretty busy as well.
<P>
So, after chatting at some length with Phil Hughes about this, I've decided to
turn the Linux Gazette over to the Linux Journal. I think that the Gazette
has demonstrated the &quot;proof of concept&quot; -- that a freely available
and open-to-all online publication is a great means for sharing information
and ideas. There are a number of great things that <I>could</I> be done with
this and I'm excited about the Gazette continuing on in this tradition.
<P>
Also, please know that the Linux Gazette has been, is, and will continue to be
an absolutely free publication. I can't stress this enough: I know that many
folks feel passionately about keeping Linux from <I>any</I> commercialization
whatsoever. I happen to disagree with this as it's my feeling that a free and
a commercial side can peacefully coexist and actually encourage and support
each other. That said, I've really enjoyed knowing that the Gazette has been
freely available to all and that it will continue to be so.
<P>
So, how about that for Cool Mojo! :-)
<P>
And what will happen to Your's Truly...?
<P>
What do you think... I'm gonna disappear? :-)
<P>
No, I'm pretty excited about the prospect of starting a regular column and
getting back to doing more reading, tinkering, and writing. With Phil's
permission, I'd like to continue to be very much involved with the Gazette
from the standpoint of supporting it and contributing to it -- and I'd
strongly encourage all of you to do the same. See... the reality of it is
that the folks at Linux Journal aren't going to get a red cent for doing all
of this. Now, admittedly, it's good P.R. for them -- and justifiably so since
they've been contributing to the Linux Community now for some time -- but that
doesn't change the fact that the work has to be done.
<P>
Anyway, thanks to you all!
<P>
Looking forward to another great year!
<P>
John M. Fisk
<HR>
<!-- ===================================================================== -->
<!-- MAILBAG ============================================================= -->
<H2><A NAME="mail"><IMG ALIGN=MIDDLE SRC="../gx/mail.gif">Salutations and the
MailBag </A></H2>
<H3><A HREF="./mailbag_issue8.html">Mail Bag for Issue #8</A></H3>
Well, I'm indebted again to the many of you who took time out of busy
schedules to drop a note of encouragement, thanks, correction, clarification,
suggestion, or article! I had a bit of an &quot;E-Mail Brown-out&quot; here
recently and so a number of you got replies dated weeks after you original
message was sent. I apologize for this. I've tried hard to keep up with
answering everyone that drops me a note. I *think* I'm back on track now...
<P>
Anyway, because it's been such a LONG time since I've gotten an issue out, and
because so many of you wrote, I've moved the entire <B>Mailbag</B> section to
its own page. This should make it a bit easier to look over.
<P>
PLEASE! Don't miss the stuff in these letters!
<P>
I'm serious. They have a LOT of great pointers, info, suggestion, tips,
corrections, and the like! While you might want to check out some of the
articles first, don't miss this!
<P>
Enjoy!
<P>
John
<P>
<A HREF="#toc"><IMG ALIGN=BOTTOM SRC="./gx/toc.gif"></A>
<A HREF="mailto: fiskjm@ctrvax.vanderbilt.edu"><IMG ALIGN=BOTTOM
SRC="./gx/sendmail.gif"></A>
<A HREF="./gazette_toc.html"><IMG ALIGN=BOTTOM SRC="./gx/index.gif"></A>
<A HREF="./linux/linux.html"><IMG ALIGN=BOTTOM SRC="./gx/home.gif"></A>
<BR><BR>
<HR>
<!-- ===================================================================== -->
<!-- QUICK TIPS SECTION ================================================== -->
<H2><A NAME="tips"><IMG ALIGN=BOTTOM SRC="../gx/text.gif">More 2&#162; Tips!
</A></H2>
<P>
<!-- ===================================================================== -->
<P>
<H3><IMG ALIGN=BOTTOM SRC="./gx/opus.gif">PWD and the Prompt!</H3>
<P>
From d93002@rsl.rtc-limerick.ie Wed Jun 26 20:19:05 1996<BR>
Date: Wed, 26 Jun 1996 13:28:26 +0100<BR>
From: &quot;Lt.Cmdr.Worf&quot; &lt;d93002@rsl.rtc-limerick.ie&gt;<BR>
To: fiskjm@ctrvax.Vanderbilt.Edu<BR>
<P>
Hello,
<P>
Congratulations on your Linux Gazette, I found it to be a helluva
magazine!:) Here is an interesting little trick that you can achieve in
the ol' Linux, customising your shell prompt! Unwittingly I discovered
ages ago, you can use escape codes to produce colors et al. The article
was very recent and covered escape codes, issue 6 or 7 I think...Have
you ever wondered what directory you're in and suddenly type in rm * to
realise you were in a directory where there's precious backups etc..and
blame yourself for not pwd'ing!!!! Fear not, this little trick will tell
you what subdirectory your in each time you log in, and stays there put
until you log out!!!!!!!!!
<P>
Notation: ^[[ is accomplished by hitting Ctrl+Shift+v then Esc and the key '['!<BR>
PS1='^[[s^[[0;0H^[[K^[[0;37;44mPwd:^[[1;38;40m$(pwd)^[[u\$'<BR>
<P>
In case you're wondering, this is the ANSI escape sequences to do:<BR>
<BLOCKQUOTE>
<P>
a) save the cursor position (^[[s)<BR>
b) Goto the top of screen 0 0 (^[[0;0H) <BR>
c) Clear the line at top of screen (^[[K)<BR>
d) print the message Pwd in its colour, consult DOS manual on ANSI codes [0;37;44m)<BR>
e) print the actual directory in it's colour (^[[1;38;40m$(pwd)) $(pwd) will print the directory<BR>
f) Restore the cursor position (^[[u)<BR>
g) Y'all should know that \$ will display $ if you're not root otherwise displays #<BR>
</BLOCKQUOTE>
<P>
Hey presto, your directory is displayed on the top of the screen -
pretty nifty eh! You can stick that into your /etc/profile or
~/.profile. You can customise it to display terminal type by specifying
$(tty) etc..... Use your imagination. I came across something similar
to that in DOS, and seems to work!!! :) :)
<P>
Cheers,<BR>
Tom Brennan.<BR>
eMail Address: d93002@rsl.rtc-limerick.ie <BR>
url: http://www.geocities.com/SiliconValley/7159<BR><BR>
Again, I send my heartiest congrats on your magazine and keep it up, <BR>
where would us linux gurus be without you! :) :) ;)<BR>
<!-- ===================================================================== -->
<!-- ===================================================================== -->
<H3><IMG ALIGN=BOTTOM SRC="./gx/opus.gif">Prompt Clean-up!</H3>
Date: Wed, 17 Apr 1996 12:15:12 CDT<BR>
From: Edgar Greuter &lt;edgar@inm.uni-sb.de&gt;<BR>
To: fiskjm@ctrvax.Vanderbilt.Edu<BR>
Subject: Small Tip for the Shell-Prompt<BR>
<P>
Hi!
<P>
I have a small tip for another useful prompt modification. Even though
i know about the less-program and its ability to display binary files, i
often have the (bad) habit to just type a
<PRE>
more *
</PRE>
<P>
in the directory of a new program to get an overview of the thing. And
sometimes there is this little devil ^N who puts my console in graphics
mode.
<P>
This week, it happened again. Getting tired about echoing the necessary
^O to the terminal by hand, i've put it in my prompt:
<PRE>
export PS1=${PS1}^O
</PRE>
(as usual, ^O means control-O and is input as Ctrl-V CTRL-O in vi).
Now any graphics mode is fixed at least at the next shell-prompt.
<P>
- Edgar
<!-- ===================================================================== -->
<!-- ===================================================================== -->
<P>
<H3><IMG ALIGN=BOTTOM SRC="./gx/opus.gif">Postscript Printing on Deskjets!</H3>
Date: Sun, 19 May 1996 15:33:10 CDT<BR>
From: Claudio Bardelle &lt;clbard@mbox.vol.it&gt;<BR>
To: fiskjm@ctrvax.Vanderbilt.Edu<BR>
Subject: My 2cent's worth<BR>
<P>
Hello John,
<P>
Thank you so much for the time you spend maintaining the Gazette. I've
learned such a lot from it! Keep up your great job!
<P>
So here's my 2 cent's worth:
<P>
I was looking for a way to print Postscript files on my Deskjet using
Ghostview, since I often only need to print a few pages from large
documents. In other words, I was looking for something a little more
flexible than using ghostscript directly. What I did was to add the
following filter to /etc/printcap (filter are stored in
/usr/local/lib/hp510)
<PRE>
---------------------------------------------------------
lp|hp510:\
:lp=/dev/lp1:\
:sd=/usr/spool/lpd/hp510:\
:if=/usr/local/lib/hp510/lpfilter:sh:
ghost|hp510ghost:\
:lp=/dev/lp1:\
:sd=/usr/spool/lpd/hp510:\
:if=/usr/local/lib/hp510/lpfilter-ps:sh:
---------------------------------------------------------
</PRE>
<P>
where
<PRE>
lpfilter
---------------------------------------------------------
#!/bin/sh
# Filter for HP printers to treat LF as CRLF
# the ``echo -ne'' assumes that /bin/sh is really bash
echo -ne \\033\&amp;k2G
cat
echo -ne \\f
---------------------------------------------------------
lpfilter-ps (remember to chmod a+x lpfilter-ps)
---------------------------------------------------------
#!/bin/sh
# Filter for HP printers to print Postscript files
gs -sDEVICE=djet500 -sPAPERSIZE=a4 -sOutputFile=- -q -
---------------------------------------------------------
</PRE>
<P>
I use 'lp' to print text, avoiding the 'staircase effect' (A tip I
'reaped' off one of you first lg issues), while I use 'ghost' to print
Postscript files. It's also useful for printing manual pages:
man -t manpage | lpr -Pghost
<P>
Regards,<BR>
Claudio<BR>
<!-- ===================================================================== -->
<!-- ===================================================================== -->
<H3><IMG ALIGN=BOTTOM SRC="./gx/opus.gif">VI paragraph formatting!</H3>
Date: Wed, 17 Apr 1996 15:22:58 CDT<BR>
From: Pat Traynor &lt;pat@ssih.com&gt;<BR>
To: fiskjm@ctrvax.Vanderbilt.Edu<BR>
Subject: vi justification<BR>
<P>
Here's a modification on a vi tip that was offered a few issues ago.
<P>
In my .exrc file, I have the following entry:
<PRE>
map ^P {!}fmt^M
</PRE>
<P>
(The &quot;^P&quot; and &quot;^M&quot; are actual control characters that I had to escape with
a &lt;ctl&gt;-V.)
<P>
When the cursor is anywhere within a paragraph and I hit a &lt;ctl&gt;-P, it
re-aligns all of the text. It's just the thing for those occasions when
you've typed in a long paragraph and then decide to delete or add several
words near the top.
<P>
I won't go into the explanation of what everything does, since that has
already been done. But rather than typing
<PRE>
:10,50! fmt
</PRE>
<P>
which requires that you know what the first and last lines of the paragraph
are, the '{' moves you to the top of the paragraph, and the trailing '}'
means to do this function up to the end of this paragraph.
<P>
--pat--<BR>
--<BR>
Pat Traynor<BR>
pat@ssih.com<BR>
<!-- ===================================================================== -->
<!-- ===================================================================== -->
<H3><IMG ALIGN=BOTTOM SRC="./gx/opus.gif">There and Back!</H3>
<P>
OK, here's a fun little ditty that I recently came across that I've really
fallen in love with :-) It's for all of those times that you find yourself
either scooting between two directories or when you've been working in one
directory, momentarily 'cd' to another, and then need to get back to wherever
it was that you originally were at. (How about that for a run on sentance...
:-) I'm sure that I could do better with a bit of a running start and a good
tail wind...)
<P>
Anyway, I'm sure that most all of you know that the 'cd' command -- a shell
builtin function -- in BASH will automagically wisk you back to your home
directory if it's invoked without an argument. That is, if you simply type
in:
<PRE>
% cd
</PRE>
at the prompt, you'll suddenly find yourself back in your home directory from
anywhere in the system. So... this is a great little thing to remember for
all you absentminded folks that have a tendency to wander a bit. You know...
some poor freshman with a note pinned to his/her shirt: &quot;If you find me,
please return me to my $HOME: my address is 'cd'&quot;.
<P>
Anyway, for all you BASH shell users out there, here's a bit of handiness
that goes a step beyond this and lets you find your way back to the directory
that you previously were in.
<P>
For instance, suppose that you're tooling along on some seriously cool Tcl/Tk
proggie and you realize that a bit of code from one of the demo apps might
come in handy for some little problem you've been having. No problem mon...
You just do the 'ol
<PRE>
% cd /usr/lib/tk
</PRE>
and have a look around for the code you've been looking for. OK, now you've
found it and everything's groovy (I just heard on the radio the other day,
BTW, that &quot;groovy&quot; is &quot;cool&quot; once again -- you know, no
one is using it, so it's &quot;hip&quot; once again, because pretty soon
everyone will be using it... I know, I know... I'm starting to ramble. Better
check the note my wife pinned to my shirt this morning... :-) anyway, where
were we...
<P>
Oh yeah, we had just stopped by the 'ol TK demo subdir to do a bit of GPL'd
plagerism and need to get back to GO. Well, there's a VERY EASY way to do
this that isn't at all intuitively obvious -- unless you've already read
through all 80 pages of the BASH manual page and then if you have -- what are
you doing hanging around here!!?
<P>
Well, to get back, you simply type in:
<PRE>
% cd ~-
</PRE>
that's a 'cd' with one of those squiggly lookin' things that lives up in the
upper left hand corner of the keyboard (a <I>tilde</I> I believe :-) and a
&quot;dash&quot; (or minus sign).
<P>
Do this and <I>Presto!</I> you're back in the 'ol neighborhood again!
<P>
Seriously Mucho Cool, eh?
<P>
Thought you'd like this one :-) And if you act now, you'll get at no extra
cost a set of 8 Ginzu knives... They slice... they dice... they.... (Hmmm... I
think it must be time for my medicine again :-)
<P>
Yeah, seriously, this one is pretty helpful. By now, you know all about using
the 'chvt' program that comes with the 'kbd' distribution -- use this one to
flit from virtual terminal to virtual terminal. Being able to do a bunch of
stuff at the same time is very cool and using 'chvt' lets you keep you hands
on the keyboard while you move from VT to VT. This same basic principle lets
you oscillate from one <I>directory</I> to another as you're working. Do the
'ol &quot;cd `-&quot; once and you're back to the directory you started in.
Do it a second time and you're back to the other directory.
<P>
Another helpful thing that you can do with this is set it up as an alias of
some kind -- use any shortcut alias you'd like. Now 'cd ~-' isn't all that
hard to write, but it's often easier to make up a quick alias. I use:
<PRE>
alias cdup='cd ~-'
</PRE>
so that I can type in 'cdup' and I'll 'cd' back up to wherever it was that I
was last at.
<P>
How about that, eh?
<P>
You know, you have to admit that the Linux Gazette can never be accused to
being <B>vaporware</B> but, truth be told, it occasionally is
<B>gaseousware</B> I mean, where else could you find an entire two pages of
verbal meanderings that boil down to, &quot;if you type 'cd ~-' you'll change
to the directory you were last in.&quot;
<P>
Think of it as getting your money's worth...
<P>
Seriously, for those of you who might be interested, this is an example of
<B>TILDE EXPANSION</B> which is a feature of the BASH shell. Check the manual
page for more info.
<P>
Enjoy! :-)
<P>
John
<!-- ===================================================================== -->
<!-- ===================================================================== -->
<H3><IMG ALIGN=BOTTOM SRC="./gx/opus.gif">HTML Clean up Macro</H3>
<P>
OK, here's another fun little item that can save you HTML authors out there a
bit of time. I've been doing a bit of writing over the past year and
repeatedly come back to <B>VIM</B> as my hands-down favorite editor for simply
getting things done. It's one of those editors which, if you keep you fingers
on the keyboard and not have to peek all the time or feel compelled to push a
mouse or other small rodent around to get work done, let's you get things done
VERY quickly. Now, you can say the same thing about <B>Emacs</B> I suspect,
but since I'm still using 'ol VI, you're stuck having to listen to me talk
about this for the moment :-)
<P>
Anyway, one of the cool things about VI is the &quot;:so&quot; command which
basically let's you create a series of command-mode commands which you save to
a text file, and then you can simply have VI &quot;source&quot; this in order
to run the commands.
<P>
Since there's nothing like a good example to clear things up, let's see how to
use this with doing a bit of pre-formatting for HTML.
<P>
As you all know, there are several characters which are not
&quot;allowed&quot; to be directly included in the text portion of an HTML
document -- these are the &quot;reserved&quot; characters and they include:
<UL>
<LI>the ampersand character: &amp;
<LI>the less-than character: &lt;
<LI>the greater-than character: &gt;
<LI>the double-quote character: &quot;
</UL>
When a browser parses the HTML document these characters are used to convey
formatting or other information and so cannot be directly input.
<P>
The problem comes in when you want to include text in an HTML document.
Specifically, I include a lot of email in the 'ol LG. Problem is, that much
of it contains so-called &quot;reserved characters&quot; -- those characters
enumerated above that should not be directly entered into the text. In the
past I've manually searched through each letter trying to ferret these out
but, as with most Linux things, there's a MUCH easier and more efficient way
to do this.
<P>
As your Uncle Louigi says, &quot;Use your head, not your back...&quot;
<P>
So, the first thing to note is that the first step in the email-&gt;HTML
conversion is converting these characters to either a &quot;Character
Reference&quot; or an &quot;Entity Reference&quot; (you know -- you have to
use &amp;quot; for the (&quot;) double-quote character). You can easily do
this using something like:
<PRE>
:%s/\&amp;/\&amp;amp;/g
</PRE>
This particular command does a global substitution for the current file by
converting every instance of &quot;&amp;&quot; to &quot;&amp;amp;&quot;. Do
this for the other three reserved characters and you'll be on your way to
dropping your email (or any other text document for that matter) into your
HTML docs.
<P>
Now, you could obviously just enter these commands in by hand each time you
want to do this, but hey, this is Linux and being lazy is OK -- as long as
you're <I>smart</I> about it :-)
<P>
So, instead of typing in a set of commands to convert these characters to
their Entity Reference format, we'll just set up a macro file which can be
sourced for any text file. Using something like:
<PRE>
%s/\&amp;/\&amp;amp;/g
%s/&lt;/\&amp;lt;/g
%s/&gt;/\&amp;gt;/g
%s/\&quot;/\&amp;quot;/g
</PRE>
will let you convert these automagically. So, how do you do this? Easy:
<OL>
<LI>Create a plain text file and copy the above lines to it
<LI>Save the file with some catchy little title such as &quot;htmlconv&quot;
<LI>Load up some test document that you want to experiment on
<LI>Now, just issue the command &quot;;so /path/to/file/htmlconv&quot;
</OL>
and <I>Presto!!</I> VI will grind away for a moment and all of the changes
will be made for you.
<P>
Sourcing a macro file is one way to improve the speed and efficiency of doing
things under VI(M) -- especially if you find yourself doing tasks that
required frequent repetition. One small suggestion is to put these macros in
their own directory off your HOME directory so that they are easily accessible
from anywhere in the directory tree. To specify such a macro you could enter:
<PRE>
:so ~/macros/htmlconv
</PRE>
and the tilde (~) would be automagically expanded out to point to your home
directory.
<P>
Anyway, this is one of those &quot;tip of the iceburg&quot; types of things
because there is a HUGE amount of mischief you can get into using macros :-)
<P>
Have fun!
<P>
John
<!-- ===================================================================== -->
<!-- ===================================================================== -->
<H3><IMG ALIGN=BOTTOM SRC="./gx/opus.gif">Getting Rid of ^M's</H3>
<P>
OK, I *promise* to keep this one nice and short.
<P>
If you use Linux long enough you'll eventually find yourself with an annoying
case of &quot;^M&quot; infestation in some file you've just created or are
working on. For my Comp Sci classes this past year I was required to do a
&quot;script&quot; output for each of my progamming projects: start the
'script' program, 'cat' the source file, compile it, and then run it. This
created a log file which had to be turned in. One of the most annoying things
about doing this was, at least on my Linux box, that it was replete with
&quot;^M&quot; at the end of each line. You'll also find that occasional DOS
files will have these scattered all throughout them as well.
<P>
So, how do you get rid of them without resorting to an exterminator...?!
<P>
Glad you asked :-)
<P>
A while ago, there was a thread in one of the comp.os.linux.xxxxx gruops about
this very subject. I'd discovered how to get rid of the ^M's easily from
within VIM but a number of other of suggestions were made as well and so I'll
present these. I apologize to their original authors. I wrote the ideas down
but neglected to write down who offered them. If you recognize any of these
as &quot;your's&quot; then please drop me a note and I'll be glad to give
credit where credit is due.
<P>
Anyway, here's how:
<DL>
<DT>From within VIM use the command <B>:%s/^V-RETURN//g</B>
<DD>You'll need to get out of edit mode to do this one (hit ESC). Enter
a colon, percent sign, the letter 's', and a forward slash. Now, you'll
need to use the Ctrl-V key combination to enter a literal key: hit the
control and 'v' key together and then hit the ENTER (or RETURN) button
which should display a '^M'. Now, hit two more forward slashes and the
letter 'g'. Hit ENTER and you're done!
<P>
What this does is a global substitution through the entire file. Each
occurrence of the ^M (which is a &quot;carriage return&quot; -- remember
that UNIX uses only the line feed (LF) character to start a new line
whereas DOS uses the carriage return + line feed characters (CR + LF) to
start a new line) is substituted by, well, nothing. So this effectively
erases each occurrence of the ^M.
<P>
<DT>At the command line use <B>sed</B>
<DD>You can use 'sed' (the Stream Editor) to trim out those unwanted ^M's
in a couple different ways:
<PRE>
% sed 's/^M//' < ORIG.FILE > new.file
-OR-
% sed 's/.$//' < ORIG.FILE > new.file
</PRE>
Just a couple points here...
<P>
For the first example the &quot;orig.file&quot; is the file that you wish
to remove the ^M's from and the &quot;new.file&quot; is what you want to
call the edited file. <B>Don't use the same filename!</B> If you do,
you'll be sorry as the contents of your original file will be deleted by
doing this. <I>Caveat Emptor!</I>
<P>
Also, the &quot;^M&quot; is the same control-v + RETURN combination
mentioned above. The standard UNIX editors VI and Emacs both let you
insert characters literally (this let's you insert characters such as the
Escape key that are normally non-printing keys). The Bourne shells tend
to use VI keymappings and the C-shells tend to use Emacs binding. Thus,
if you're using BASH you'll use control-v to insert a literal character at
the command line and then hit ENTER (or RETURN) to insert a literal
carriage return character.
<P>
The second example doesn't use any of this type of literal character stuff
-- just type it in as you see it and it'll work!
<P>
<DT>Pipe the file through <B>tr</B>
<DD>You can use the 'tr' (translate) utility to accomplish the same basic
thing by doing something like:
<PRE>
cat orig.file | tr -d \\r &gt; new.file
</PRE>
Again, there's no tricky literal character input here; you just type it in
as listed above. Do note, however, that you <I>pipe</I> the output of the
'cat' operation to 'tr' and then <I>redirect</I> the output from 'tr' to
the new file you wish to create. And don't forget to use a different name
for the new file!
<P>
</DL>
<P>
Well, hopefully, that should get you going!
<P>
Enjoy.
<P>
John
<P>
<A HREF="#toc"><IMG ALIGN=BOTTOM SRC="./gx/toc.gif"></A>
<A HREF="mailto: fiskjm@ctrvax.vanderbilt.edu"><IMG ALIGN=BOTTOM
SRC="./gx/sendmail.gif"></A>
<A HREF="./gazette_toc.html"><IMG ALIGN=BOTTOM SRC="./gx/index.gif"></A>
<A HREF="./linux/linux.html"><IMG ALIGN=BOTTOM SRC="./gx/home.gif"></A>
<BR><BR>
<HR>
<!-- ==================================================================== -->
<!-- SECTION 3 ========================================================== -->
<H2><A NAME="bardj"><IMG ALIGN=BOTTOM SRC="../gx/text.gif">PPPD Tips -n- Tricks
</A></H2>
<P>
<H3><A HREF="http://www.colargol.idb.hist.no/~bardj/lg/pluggin1.html">
http://www.colargol.idb.hist.no/~bardj/lg/pluggin1.html</A></H3>
<P>
by <B>Baard Johannessen &lt;bardj@utopia.ppp.sn.no&gt;</B>
<P>
After a request for help in the last LG a number of folks wrote and offered to
help, including <B>Baard Johannessen</B> who offered to write an article on
using PPP including all the fun things that you can do with it! His URL is
listed above and the letter he sent describing it is included below.
<P>
Thanks Baard!
<BLOCKQUOTE>
<P>
Date: Wed, 17 Apr 1996 23:12:43 CDT<BR>
From: Baard Johannessen &lt;bardj@colargol.idb.hist.no&gt;<BR>
To: fiskjm@ctrvax.Vanderbilt.Edu<BR>
Subject: Writing for the Linux Gazette<BR>
<P>
Hello!
<P>
I am writing to you today in response to your request for help with the
Linux Gazette.
<P>
I feel that if there is one area where Linux proves it's strength it is when
connecting a PC to a TCP/IP network. Seeing as more an more people get
access to PPP dialup accounts, I think it would be nice with a column about
all the things you could do using such a connection. The thing is: If you
got a PPP connection to the Internet, you got your own IP address, you can
actually do anything anyone else does.
<P>
I have a Linux machine connected to our company LAN. On it's responsible for
retrieving our eMail, it runs a Web server and FTP server. It runs a news
server for our LAN, downloading a selected set of newsgroups whenever it
goes online. It's got sendmail configured (like you described in a previous
issue of LG) to queue remote mail, while delivering local mail immediately.
It also function as our Internet gateway, by using something called
IPMasquerade. This enables all the machines on our LAN to access the
Internet through this machine, and without the cooperation of our ISP (saves
us equivalent of hundreds, if not thousands of dollars).
<P>
Such a column would start with the basics of setting up PPP, sendmail,
popclient and things like that. Then we could move to other interesting
things like setting up a news server, a Web server and a FTP server.
Obviously some security stuff would also be needed.
<P>
If you thing a column like this would be a good idea, please feel free to
get back to me.
<P>
It's not like I don't have enough to do, but I spend quite a lot of time
with Linux already, and a project like this would be a great way for me to
document some of the thing I do. I will start setting up a similar system
for a client shortly, so I could probably take a lot of this stuff from my
notes on that system.
<P>
I have the ability to produce on a regular basis (once a month, wasn't it?
:), and the time to receive and READ any eMail it my writing generates. I'm
also quite capable of writing HTML.
<P>
Anyway, you probably get a lot of eMail, so I think it's time for me to shut
up, and await your reply.
<PRE>
,,,
(o o)
================================oOO==(_)==OOo=================================
Baard Johannessen Phone : (+ 47) 33 13 00 93
bardj@colargol.idb.hist.no Private : (+ 47) 94 41 27 47
http://www.colargol.idb.hist.no/~bardj/ Fax : (+ 47) 33 13 03 13
.oooO Oooo. Cell : (+ 47) 90 82 79 66
================================( )==( )==================================
\ ( ) /
\_) (_/
</PRE>
<P>
Date: Thu, 11 Jul 1996 06:52:07 +0100<BR>
From: Baard Johannessen &lt;bardj@utopia.ppp.sn.no&gt;<BR>
Reply-To: bardj@colargol.idb.hist.no<BR>
To: fiskjm@ctrvax.Vanderbilt.Edu<BR>
Subject: Re: Column for the LG<BR>
<P>
Just writing to remind you I allready have done the first column. You have
seen it, but seeing how things have &quot;gotten a LOT more out of hand than you
had anticipated&quot; I thought I'd remind you :)
<P>
Look it up at:
<A HREF="http://www.colargol.idb.hist.no/~bardj/lg/pluggin1.html">
http://www.colargol.idb.hist.no/~bardj/lg/pluggin1.html</A>
<P>
Regards<BR>
bardj (looking forward to the next issue)<BR>
</BLOCKQUOTE>
<P>
<A HREF="#toc"><IMG ALIGN=BOTTOM SRC="./gx/toc.gif"></A>
<A HREF="mailto: fiskjm@ctrvax.vanderbilt.edu"><IMG ALIGN=BOTTOM
SRC="./gx/sendmail.gif"></A>
<A HREF="./gazette_toc.html"><IMG ALIGN=BOTTOM SRC="./gx/index.gif"></A>
<A HREF="./linux/linux.html"><IMG ALIGN=BOTTOM SRC="./gx/home.gif"></A>
<BR><BR>
<HR>
<!-- ===================================================================== -->
<!-- SECTION 4 =========================================================== -->
<H2><A NAME="gcapell"><IMG ALIGN=BOTTOM SRC="../gx/text.gif">The <I>Wily</I>
Text Editor</A></H2>
<P>
<H3><A HREF="http://www.cs.su.oz.au/~gary/wily/">
http://www.cs.su.oz.au/~gary/wily/</A></H3>
<P>
by <B>Gary Capell &lt;gary@cs.su.oz.au&gt;</B>
<P>
Here's a review of the <B>Wily Text Editor</B> which is fashioned after
<B>Plan 9's Acme Text Editor</B>. Take a look and see what you think!
<BLOCKQUOTE>
<P>
Date: Mon, 10 Jun 1996 18:02:05 CDT<BR>
From: Gary Capell &lt;gary@cs.su.oz.au&gt;<BR>
To: fiskjm@ctrvax.Vanderbilt.Edu<BR>
Subject: possible addition to &quot;Editors&quot; section of linux_toys<BR>
<P>
<A HREF="http://www.cs.su.oz.au/~gary/wily/">
http://www.cs.su.oz.au/~gary/wily/</A>
<P>
Let me know what you think?<BR>
-- <BR>
http://www.cs.su.oz.au/~gary/<BR>
</BLOCKQUOTE>
<P>
<A HREF="#toc"><IMG ALIGN=BOTTOM SRC="./gx/toc.gif"></A>
<A HREF="mailto: fiskjm@ctrvax.vanderbilt.edu"><IMG ALIGN=BOTTOM
SRC="./gx/sendmail.gif"></A>
<A HREF="./gazette_toc.html"><IMG ALIGN=BOTTOM SRC="./gx/index.gif"></A>
<A HREF="./linux/linux.html"><IMG ALIGN=BOTTOM SRC="./gx/home.gif"></A>
<BR><BR>
<HR>
<!-- ===================================================================== -->
<!-- SECTION 5 =========================================================== -->
<H2><A NAME="jphilbrook"><IMG ALIGN=BOTTOM SRC="../gx/text.gif">Monitoring a
Link with SNMP</A></H2>
<P>
<H3><A HREF="http://www.midcoast.com/~jp/snmp.html">
http://www.midcoast.com/~jp/snmp.html</A></H3>
<P>
by <B>Jason Philbrook &lt;jp@midcoast.com&gt;</B>
<P>
Here's an article about...
<BLOCKQUOTE>
<P>
Date: Tue, 14 May 1996 20:47:50 CDT<BR>
From: jason philbrook &lt;jp@midcoast.com&gt;<BR>
To: fiskjm@ctrvax.Vanderbilt.Edu<BR>
Subject: linux gazette<BR>
<P>
If you're looking for material for the linux gazette,
consider a page I made explaining SNMP and a bit
of simple shell scripts.
<P>
<A HREF="http://www.midcoast.com/~jp/snmp.html">
http://www.midcoast.com/~jp/snmp.html</A>
<P>
-Jason Philbrook
</BLOCKQUOTE>
<P>
<A HREF="#toc"><IMG ALIGN=BOTTOM SRC="./gx/toc.gif"></A>
<A HREF="mailto: fiskjm@ctrvax.vanderbilt.edu"><IMG ALIGN=BOTTOM
SRC="./gx/sendmail.gif"></A>
<A HREF="./gazette_toc.html"><IMG ALIGN=BOTTOM SRC="./gx/index.gif"></A>
<A HREF="./linux/linux.html"><IMG ALIGN=BOTTOM SRC="./gx/home.gif"></A>
<BR><BR>
<HR>
<!-- ===================================================================== -->
<!-- SECTION 6 =========================================================== -->
<H2><A NAME="ntjirkalli"><IMG ALIGN=BOTTOM SRC="../gx/text.gif">Using JAVA and
Netscape 2+</A></H2>
<CENTER>
<H3>Using The JAVA Compiler In Netscape 2+ To Compile JAVA Classes</H3>
</CENTER>
<CENTER>
<P>by <B>Nic Tjirkalli &lt;nic@pipex-sa.net&gt;</B>
</CENTER>
<BR><P>
The <B>Java Development Kit (JDK)</B>, ported to Linux by the kind folks
at <B>Blackdown</B>, allows Linux users to compile java source code to produce java class
files. However, the JDK requires a <B>Linux ELF</B> system and will
not work on an <B>a.out</B> system. The Netscape Navigator (version 2.0
and higher) contains a java compiler which can be used to compile
java source code on <I>a.out</I> and <I>ELF</I> Linux systems.
<BR><P>
<BR><P>
<H3>REQUIREMENTS</H3>
<BR><P>
You will need the following bits of software :-
<BR><P>
<OL>
<LI>
<B>The Netscape Navigator For Linux.</B><BR><P>
This is available at
<A HREF="ftp://ftp.netscape.com/pub/navigator/2.01/unix/netscape-v201-export.i486-unknown-linux.tar.gz">
Netscapes's site</A> or from one of its numerous mirror sites. INSTALL netscape
as per the instructions in the readme.
<BR><P>
<BR><P>
<LI>
<B>The classes.zip File From The JDK</B><BR><P>
You will need to pull down part of the Linux JDK port and extract the
<B>classes.zip</B>
file. Proceed as follows :-
<BR><P>
<UL>
<LI>
Pull down
<A HREF="ftp://java.blackdown.org/pub/Java/linux/linux.jdk-1.0.1-try1.common.tar.gz">
part of the Linux JDK port</A> from the Blackdown FTP site.
<BR><P>
<LI>
Extract the <I>classes.zip</I> file as follows :-
<BR><P>
<PRE>
tar -zxvf linux.jdk-1.0-try1.common.tar.gz java/lib/classes.zip
</PRE>
<BR>
This will extract the file <I>classes.zip</I> and palce it in the
<B>java/lib</B> idirectory, off the current directory.
<BR><P>
<LI>
Move the <I>classes.zip</I> file to the same directory where the
Netscape <I>moz2_0.zip</I> is located. I use :- <BR>
<CENTER>
<B>
/usr/local/netscape/java/classes
</CENTER>
</B>
with the following command :-
<PRE>
mv java/lib/classes.zip /usr/local/netscape/java/classes/.
</PRE>
<BR><P>
<LI>
You may now delete the JDK gzipped tar archive file :-
<PRE>
rm linux.jdk-1.0-try1.common.tar.gz
</PRE>
</UL>
<BR><P>
<BR><P>
<LI><B>My javacc script</B><BR><P>
I have called the script <B>javacc</B> so as not to confuse it with
the java compilere, <B>javac</B> which is available in the JDK.
Place the script whereever you want and change its permissions to make it
executable, as follows :- <BR><P>
<PRE>
chmod 555 javacc
</PRE>
<BR><P>
Basically, the script checks that a java source code file name (complete
with its extension, normally <B>.java</B>) has been entered and that the
file exists before calling the java compiler. <BR><P>
Also, the script
sets up the environment variable <B>CLASSPATH</B> to point to
the java class library include with netscape (this is the
file <B>moz2_0.zip</B> for Netscape 2.0x and <B>moz3_0.zip</B> for
Netscape Atlas) and the <B>classes.zip</B> file from the JDK.
</OL>
<PRE>
# --------------------------- javacc script begins here ----------------
#
# javacc
# Script To Use The Built In Netscape Java Compiler To Build Java Classes
# Nic Tjirkalli, April 1996 nic@pipex-sa.net
#
#
# Usage : javacc file.java
#
# NOTE : CLASSPATH must point to the files
# moz2_0.zip i(or moz3_0.zip if you are using Netscape Atlas
# and classes.zip (from the JDK)
#
# If your are using Netscape Atlas preview, the netscape classes
# file is called moz3_0.zip. Modify the CLASSPATH to point to
# this file instead of moz2_0.zip.
#
# NO WARRENTY IS PROVIDED WITH THIS SCRIPT - IT IS USED AS IS !!
# YOU MAY FREELY USE AND DISTRIBUTE THIS SCRIPT
#
#!/bin/bash
#
if [ $# -eq 0 ]
then
echo &quot; No JAVA file specified&quot;
echo &quot; javacc USAGE :- javacc java-source-code-file.java&quot;
exit
fi
if [ $# -gt 1 ]
then
echo &quot; Too Many parameters - ignoring all but the FIRST&quot;
fi
if [ -f $1 ]
then
echo &quot; Compiling -&gt; &quot; $1
#
# If you are Using Netscape Atlas, change moz2_0.zip to moz3_0.zip
# in the CLASSPATH environment variable
#
export CLASSPATH=.:/usr/local/netscape/java/classes/moz2_0.zip:\
/usr/local/netscape/java/classes/classes.zip
#
# If your netscape binary is not in /usr/X11/bin, modify the path below
#
/usr/X11/bin/netscape -java sun.tools.javac.Main $1
echo &quot;Done&quot;
else
echo &quot; JAVA file not found !! bummer......&quot;
fi
#
# --------------------------- javacc script begins here ----------------
#
<BR><P>
<BR><P>
</PRE>
<H3>USAGE</H3>
To use the <B>javacc</B> script, invoke it as follows :-
<BR><P>
<CENTER><I>
javacc java-source-file.java
</I></CENTER>
<BR><P>
<B>USAGE NOTES:</B>
<OL>
<LI>
The script checks to see if a source file parameter has been entered. If
no parameter is specified, the script comes up with a usage message.
<BR>
<LI>
If multiple command line parameters are entered, the script only uses
the first parameter as the java source code file name and ignores all
other parameters
</OL>
<BR><P>
If the java compilation is successful, a java bytecode file, with
the extension <B>.class</B> is created. This is the java applet.
<BR><P>
<BR><P>
<H3>SOME INTERESTING JAVA RELATED SITES TO VISIT</H3>
<BR><P>
<UL><UL><UL>
<A HREF="http://studwww.rug.ac.be/~vwillems/JAVA/">
http://studwww.rug.ac.be/~vwillems/JAVA
</A>
</UL>
<A HREF="http://www.nebulex.com/URN/">
http://www.nebulex.com/URN
</A>
</UL>
<A HREF="http://www.gamelan.com/">
http://www.gamelan.com
</A>
</UL>
<HR SIZE = 1>
<A HREF="http://www.pipex-sa.net/~nic/">Nic Tjirkalli </A>
<ADDRESS>
<A HREF = "mailto:nic@pipex-sa.net">
nic@pipex-sa.net</A>
</ADDRESS>
<P>
<A HREF="#toc"><IMG ALIGN=BOTTOM SRC="./gx/toc.gif"></A>
<A HREF="mailto: fiskjm@ctrvax.vanderbilt.edu"><IMG ALIGN=BOTTOM
SRC="./gx/sendmail.gif"></A>
<A HREF="./gazette_toc.html"><IMG ALIGN=BOTTOM SRC="./gx/index.gif"></A>
<A HREF="./linux/linux.html"><IMG ALIGN=BOTTOM SRC="./gx/home.gif"></A>
<BR><BR>
<HR>
<!-- ===================================================================== -->
<!-- SECTION 7 =========================================================== -->
<H2><A NAME="ecame"><IMG ALIGN=BOTTOM SRC="../gx/text.gif">Web Surfer!</A></H2>
<H3><A HREF="./websurfer_issue8.html">This Month's <I>Web Surfer!</I></A></H3>
<P>
by <B>Ed Cameron &lt;ecame119@ecity.net&gt;</B>
<P>
Once again, if you're up to doing a bit of <I>Web Surfin'</I> then have a peek
at all the of seriously fun place to have a look at. This month's WS includes
a look at <B>TkNet</B>, some pretty funky lookin' stuff from <B>Sega</B>,
<B>Lions, Tigers, and Bears!</B> (...Oh My!), and other nifty ramblings.
<P>
Thanks Ed!
<P>
Enjoy!
<P>
<A HREF="#toc"><IMG ALIGN=BOTTOM SRC="./gx/toc.gif"></A>
<A HREF="mailto: fiskjm@ctrvax.vanderbilt.edu"><IMG ALIGN=BOTTOM
SRC="./gx/sendmail.gif"></A>
<A HREF="./gazette_toc.html"><IMG ALIGN=BOTTOM SRC="./gx/index.gif"></A>
<A HREF="./linux/linux.html"><IMG ALIGN=BOTTOM SRC="./gx/home.gif"></A>
<BR><BR>
<HR>
<!-- ===================================================================== -->
<!-- SECTION 8 =========================================================== -->
<H2><A NAME="layers"><IMG ALIGN=BOTTOM SRC="../gx/text.gif">TkDesk, FTE,
Process Meters, html-helper-mode, and a Whole Lot More!</A></H2>
<H3><A HREF="misc.html">New Releases &amp; Revisions</A></H3>
<H3><A HREF="tkdesk.html">Introduction to TkDesk</A></H3>
<H3><A HREF="vm-emacs.html">VM- &amp; Html-Helper-Mode for Emacs</A></H3>
<P>
by <B>Larry Ayers &lt;layers@vax2.rain.gen.mo.us&gt;</B>
<P>
Well, once again I owe a HUGE debt of thanks to <B>Larry Ayers</B> for his
absolutely wonderful and prolific reviews of a LOT of great software. His
first document on <B>New Releases and Revisions</B> includes reviews of:
<UL>
<LI>An Nedit that works
<LI>ELF-based Andrew User Interface System (AUIS)
<LI>FTE: A Folding Editor from the OS/2 World
<LI>TkEdit: An Editor Worth Investigating
<LI>A Couple New Process Meters
</UL>
<P>
His next review takes a look at an impressive <B>Tcl/Tk</B> based desktop
management utility: <B>TkDesk</B>. And finally, there's a review of the
<B>VM- and html-help-modes</B> available for Emacs.
<P>
These are GREAT reviews. There are some very nice descriptions and
screen shots for several programs. Drop Larry a note (and for that
matter, drop <I>any and all</I> of the contributing authors a note!) of
thanks for this!
<P>
<A HREF="#toc"><IMG ALIGN=BOTTOM SRC="./gx/toc.gif"></A>
<A HREF="mailto: fiskjm@ctrvax.vanderbilt.edu"><IMG ALIGN=BOTTOM
SRC="./gx/sendmail.gif"></A>
<A HREF="./gazette_toc.html"><IMG ALIGN=BOTTOM SRC="./gx/index.gif"></A>
<A HREF="./linux/linux.html"><IMG ALIGN=BOTTOM SRC="./gx/home.gif"></A>
<BR><BR>
<HR>
<!-- ===================================================================== -->
<!-- SECTION 9 =========================================================== -->
<H2><A NAME="gtaylor"><IMG ALIGN=BOTTOM SRC="../gx/text.gif">Shell Programming
</A></H2>
<H3><A HREF="./shell.html">Shell Programming</A></H3>
<P>
by <B>Geoff Taylor &lt;geoff@marburg.dnet.co.uk&gt;</B>
<P>
I've said this before but it certainly bears repeating: &quot;99% of all Linux
users are their own system administrators and <I>every</I> system
administrator needs to know how to shell program!&quot;
<P>
In view of this, I'm very pleased to include this great shell programming
article by <B>Geoff Taylor</B>. In this article he'll take you through the
writing of a couple pretty useful shell programs: <B>px</B> and
<B>search</B>.
<P>
I REALLY appreciate Geoff's contribution. There's a HUGE amount of fun and
useful things that can be done with a little bit of shell know-how and I'd
welcome any other such submissions!
<P>
Thanks and enjoy!
<P>
<A HREF="#toc"><IMG ALIGN=BOTTOM SRC="./gx/toc.gif"></A>
<A HREF="mailto: fiskjm@ctrvax.vanderbilt.edu"><IMG ALIGN=BOTTOM
SRC="./gx/sendmail.gif"></A>
<A HREF="./gazette_toc.html"><IMG ALIGN=BOTTOM SRC="./gx/index.gif"></A>
<A HREF="./linux/linux.html"><IMG ALIGN=BOTTOM SRC="./gx/home.gif"></A>
<BR><BR>
<HR>
<!-- ===================================================================== -->
<!-- SECTION 10 ========================================================== -->
<H2><A NAME="jwessling"><IMG ALIGN=BOTTOM SRC="../gx/text.gif">The Utility
Room!</A></H2>
<H3><A HREF="utility_room.html">The Utility Room!</A></H3>
<P>
by <B>Jens Wessling &lt;wessling@famine.emich.edu&gt;</B>
<P>
Here's an offering of even MORE great tips for using one of my admittedly
favorite programs - VI :-)
<P>
<A HREF="#toc"><IMG ALIGN=BOTTOM SRC="./gx/toc.gif"></A>
<A HREF="mailto: fiskjm@ctrvax.vanderbilt.edu"><IMG ALIGN=BOTTOM
SRC="./gx/sendmail.gif"></A>
<A HREF="./gazette_toc.html"><IMG ALIGN=BOTTOM SRC="./gx/index.gif"></A>
<A HREF="./linux/linux.html"><IMG ALIGN=BOTTOM SRC="./gx/home.gif"></A>
<BR><BR>
<HR>
<!-- ===================================================================== -->
<!-- SECTION 11 ========================================================== -->
<H2><A NAME="articles"><IMG ALIGN=BOTTOM SRC="../gx/text.gif">A Collection of
Articles</A></H2>
<H3><A HREF="./articles.html">Linux Gazette #8 Articles</A></H3>
<P>
One of the things that I've been truly amazed by over and over again is the
tremendous sense of generosity and <I>esprit de corps</I> that exists within
the Linux Community. A number of you have written and sent in articles for
the Linux Gazette. While I appreciate articles that come
&quot;pre-tagged&quot; for HTML, I also appreciate anyone's willingness to
write and share their ideas.
<P>
This collection of articles are those that I tagged up -- because time has
been such an exasperating problem recently I took the liberty of collecting
these altogether and including them in a single file (I'm afraid it isn't
quite as fancy as those many of you have sent in).
<P>
These are some <I>excellent</I> articles and I'd encourage you all to at least
skim though these as they touch on a number of very practical subjects. So
that you have an idea about what is included, here's the TOC so that you can
jump right to an article that sounds interesting to you:
<H3>Table of Contents -- Linux Gazette #8 Articles</H3>
<UL>
<LI><A HREF="./articles.html#awk">An Introduction to AWK, by Cheng Hian Goh</A>
<LI><A HREF="./articles.html#ansi">Cheap ANSI Color!, by Jim Valentine</A>
<LI><A HREF="./articles.html#dired">DIRED: Distant Relative of GNU 'ls', by Grant B.
Gustafson</A>
<LI><A HREF="./articles.html#rm">Securing your RM!, by Christophe Blaess</A>
<LI><A HREF="./articles.html#tar">TAR'ing over the Net, by Mark A. Bentley</A>
<LI><A HREF="./articles.html#tcsh">Taking Full Advantage of TCSH - precmd, by Ryan</A>
<LI><A HREF="./articles.html#xdm">Customizing Logins with XDM, by Yann Le Fablec</A>
<LI><A HREF="./articles.html#zlister">Announcing ZLISTER, by Joe Wulf</A>
</UL>
<P>
Enjoy!
<P>
<A HREF="#toc"><IMG ALIGN=BOTTOM SRC="./gx/toc.gif"></A>
<A HREF="mailto: fiskjm@ctrvax.vanderbilt.edu"><IMG ALIGN=BOTTOM
SRC="./gx/sendmail.gif"></A>
<A HREF="./gazette_toc.html"><IMG ALIGN=BOTTOM SRC="./gx/index.gif"></A>
<A HREF="./linux/linux.html"><IMG ALIGN=BOTTOM SRC="./gx/home.gif"></A>
<BR><BR>
<HR>
<!-- ===================================================================== -->
<!-- SECTION 12 ========================================================== -->
<H2><A NAME="upgrade"><IMG ALIGN=BOTTOM SRC="../gx/text.gif">Kernel 2.0 Upgrade
</A></H2>
<H3><A HREF="./upgrade.html">Experiences with Kernel 2.0 Upgrade</A></H3>
<P>
by <B>John M. Fisk &lt;fiskjm@ctrvax.vanderbilt.edu&gt;</B>
<P>
Well, I have to admit that I've been a bit of a &quot;stick-in-the-mud&quot;
until recently when comes to kernels. I'd been stubbornly running kernel
1.2.13 for months while the rest of you &quot;Bleeding Edge&quot; kinda folks
gradually ascended higher and higher into the 1.3.x kernels :-)
<P>
Since I use Linux for my Internet connection and do all of my HTML
development under it I really wanted stability. However, once the 2.0
kernel came out and <B>Michael K. Johnson's</B> article in the <B>Linux
Journal</B> provided a concise summary of the improvements from the
1.2.x -&gt; 2.0.x kernels, I decided to take the plunge.
<P>
Well, I did it and I'm pretty happy about it! :-)
<P>
It's not as bad as it sounds and it really is worth the effort. What I'd like
to do is share with you about how this upgrade went for <I>me</I>. Your
experiences will probably be different depending on the hardware that you're
running, which distribution you're using, and so forth.
<P>
Still, I really believe that it's worth the effort!
<P>
I'd be delighted to hear from any of you who've done that same thing. Drop me
a note and let me know how things went for you!
<P>
Hope you enjoy.
<P>
John
<P>
<A HREF="#toc"><IMG ALIGN=BOTTOM SRC="./gx/toc.gif"></A>
<A HREF="mailto: fiskjm@ctrvax.vanderbilt.edu"><IMG ALIGN=BOTTOM
SRC="./gx/sendmail.gif"></A>
<A HREF="./gazette_toc.html"><IMG ALIGN=BOTTOM SRC="./gx/index.gif"></A>
<A HREF="./linux/linux.html"><IMG ALIGN=BOTTOM SRC="./gx/home.gif"></A>
<BR><BR>
<HR>
<!-- ===================================================================== -->
<!-- SECTION 13 ========================================================== -->
<H2><A NAME="keys"><IMG ALIGN=BOTTOM SRC="../gx/text.gif">Of Keys, Consoles,
&amp; VT Cruisin'</A></H2>
<H3><A HREF="./keys-n-consoles.html">Keyboards &amp; Consoles</A></H3>
<P>
<B>by John M. Fisk &lt;fiskjm@ctrvax.vanderbilt.edu&gt;</B>
<P>
I recently submitted an article to the <A HREF="http://www.ssc.com">Linux
Journal</A> for the <B>Novice to Novice</B> column. I really appreciate the
generosity of the folks at the LJ and, with their permission, have included
the draft of this article here.
<P>
This particular article contains mostly stuff that I or someone else has
written about before in the LG, but for those of you who may be visiting and
who haven't seen those articles, here's a bit of information on keyboard
mapping, switching virtual terminals (VT's), and other fun stuff.
<P>
Hope you Enjoy!
<P>
John
<P>
<A HREF="#toc"><IMG ALIGN=BOTTOM SRC="./gx/toc.gif"></A>
<A HREF="mailto: fiskjm@ctrvax.vanderbilt.edu"><IMG ALIGN=BOTTOM
SRC="./gx/sendmail.gif"></A>
<A HREF="./gazette_toc.html"><IMG ALIGN=BOTTOM SRC="./gx/index.gif"></A>
<A HREF="./linux/linux.html"><IMG ALIGN=BOTTOM SRC="./gx/home.gif"></A>
<BR><BR>
<HR>
<!-- ===================================================================== -->
<!-- COLOPHON =========================================================== -->
<H2><A NAME="colophon"><IMG ALIGN=BOTTOM SRC="../gx/text.gif">Colophon</A></H2>
<P>
Well, I think we're almost ready to go. It's funny... I've mentioned this
before but I really enjoy writing this section of the LG. I purposely wait to
write this last and, kind of like coming home after a busy day, it's nice to
kick back and just chat.
<P>
As I mentioned before, I can't tell you how pleased, relieved, and excited I
am about turning the LG over to Linux Journal. I think that this will be a
Very Good Thing primarily because it deals with one of the things that
frustrated me more than anything else -- not being able to get the Gazette out
on a regular and timely fashion. I am really excited about the Gazette being
published in a more predictable fashion as I know that many of you wrote about
this.
<P>
Also, since I haven't had much time to do any serious 'Net cruisin' recently
let me share with you, if you don't mind, a project that I started tinkering
around with a while ago. One of the things that I was hoping to do over the
summer was learn a bit of <B>Tcl/Tk</B> programming. While I haven't had
nearly the amount of free time to do this as I'd hoped, I still found a bit of
time earlier this summer to play around with an X Window interface for pppd.
<P>
I have to admit, Tcl/Tk is just too much fun! Now, I'm not sure that I'd want
to be building <B>Lotus Smart Suite or Microsoft Office</B> in Tcl/Tk, but for
small project and programs this is just too much fun. What I wanted to do was
to create a front end for pppd that I could use either as 'root' or as a user.
I also wanted it to have a few little &quot;extras&quot; such as a timer, line
selection, and logging facility. Well, it turned into a LOT of fun and after
a bit of tinkering and pouring over <B>John Ousterhout's and Brent Welch's</B>
books on Tcl/Tk programming, I finally got an admittedly <I>alpha</I> version
up and running.
<P>
For the curious, here's a miniature screen dump:
<P>
<CENTER>
<IMG WIDTH=365 HEIGHT=434 SRC="./gx/ppptk_sm.gif">
</CENTER>
<P>
Hmmm... looks a bit fuzzy, eh?
Well, if you're interested, here's a <A HREF="./ppptk.html">full screen view
</A> of the program together with a brief description of what it does.
<P>
Now, I admit that I'm no serious Tcl/Tk programmer, but I've been REALLY
impressed with how well this little program works and how easy it's been to
modify it. For anyone interested, I'd be happy to send you a copy of the
sources with the proviso that you understand that this is NOT a general pppd
utility -- there are MUCH nicer and easier programs alreay available including
Tk-Net and tkppp. If you're looking for an easy to use X front end, I'd give
Tk-Net a look at. And, you're in luck, because Ed Cameron has included a
section on this very program (with some nice screen dumps) in this month's
<A HREF="#ecame">Web Surfer!</A>
<P>
Well, I've still got a bit of work to do to get the LG files ready to go. So,
it's time to &quot;Say Goodnight, Gracie!&quot;
<P>
Again, thanks to all for your kind support and for making the Linux Gazette
<I>just a bit more fun...!</I>
<P>
Cheers!
<P>
John M. Fisk<BR>
July 30, 1996
<P>
<A HREF="#toc"><IMG ALIGN=BOTTOM SRC="./gx/toc.gif"></A>
<A HREF="mailto: fiskjm@ctrvax.vanderbilt.edu"><IMG ALIGN=BOTTOM
SRC="./gx/sendmail.gif"></A>
<A HREF="./gazette_toc.html"><IMG ALIGN=BOTTOM SRC="./gx/index.gif"></A>
<A HREF="./linux/linux.html"><IMG ALIGN=BOTTOM SRC="./gx/home.gif"></A>
<BR><BR>
<HR>
<!-- ===================================================================== -->
<!-- FOOTER ============================================================== -->
<H4>Got any <I>great</I> ideas for improvements! Send your
<A HREF="mailto:fiskjm@ctrvax.vanderbilt.edu">comments, criticisms, suggestions,
and ideas.</A></H4>
<H3><A HREF="./linux/linux.html">Back up to Linux HomeBoy WebPage</A></H3>
<I>This page written and maintained by:</I><BR>
<ADDRESS>
<A HREF="./jmf.html">John M. Fisk</A> at <A HREF="mailto:fiskjm@ctrvax.vanderbilt.edu">
fiskjm@ctrvax.vanderbilt.edu</A>
</ADDRESS>
<!-- ===================================================================== -->
</BODY>
</HTML>