Article View: comp.editors
Article #3828Re: Adding Line Numbers to a text file
From: Al Aab
Date: Wed, 23 Sep 1998 00:00
Date: Wed, 23 Sep 1998 00:00
133 lines
5583 bytes
5583 bytes
1- cat -n
2- ln
3- DOS norton utilities lp (line printer w options)
4- sed onliner by al aab (more flixible, if u know sed)
see oneliners in:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
SED RESOURCES
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
to master regular expressions
to master sed
join my seders informal email list :
af137@torfree.net
----
sed web pages
"sed one liners" by Eric Pement
"Doing It with sed" by sed stud Carlos
http://seders.icheme.org/ seders grab bag (seders official web page)
http://www.dbnet.ece.ntua.gr/~george/#seders seder, engineer, Dr2b Yiorgos
THE SED FAQ
latest version of the sed FAQ is usually at:
http://seders.icheme.org/tutorials/sed_faq.txt
http://www.dbnet.ece.ntua.gr/~george/sed/sedfaq.html
http://www.ptug.org/sed/sedfaq.html
http://www.cornerstonemag.com/sed/sedfaq.html
----
http://www.math.fu-berlin.de/~guckes/sed/ seder Herr Guckes
http://www.math.fu-berlin.de/~leitner/sed/ Herr Leitner
http://www.ptug.org/sed/custom_sed.html supersed writer, seder Simon Taylor
http://www.cis.nctu.edu.tw/~gis84806/sed exotic scripts.seder Yao-Jen Chang
sed/regular expressions tutorials/refs
1- http://www.dordt.edu:457/OSUserG/BOOKCHAPTER-14.html
Chapter 14, Manipulating text with sed
2- "Doing It with sed" by sed stud Carlos (see http's above)
3- SunOS Manual Pages
http://www.intac.com/man/sunos/sed.1v.html
http://cmgm.stanford.edu/man2html/sed.1v.html
4- u-sedit2. has nice sed docs.
http://wuarchive.wustl.edu/systems/ibmpc/garbo.uwasa.fi/editor/u-sedit2.zip
5- dc UNIX stack-calculator, in sed, by sed stud GREG UBBEN
http://www.dbnet.ece.ntua.gr/~george/sed/dc.sed.html
6- sierpinski gasket/triangle, in sed, by sed stud KEN PIZZINI
posted by Al Aab, in July 1998 to
alt.comp.editors.batch & comp.unix.shell
search dejanews
----
some sed implementaions
"official" release of GNU sed-3.01 is finally available from:
ftp://ftp.gnu.org/pub/gnu/sed-3.01.tar.gz
sedmod.zip very extended/awkish DOS sed
ftp://ftp.adam.anet.cz/pub/cdrom3/fileutil/sedmod.zip
http://www.ptug.org/sed/SEDMOD10.ZIP
MKS Toolkit, windows 32 http://www.mks.com
ftp://uiarchive.uiuc.edu/pub/systems/pc/simtelnet/win95/util/
ud32_v43.zip B 3381699 980512 UnixDos: Full Unix set: 65 progs +28 new
utils
ftp://uiarchive.uiuc.edu/pub/systems/pc/simtelnet/win3/util/
ud16_v42.zip B 4767550 980313 UnixDos: Full Unix set. 64 progs +28 new
utils
----
my favourite DOS/UNIX sed :
ftp://uiarchive.uiuc.edu/pub/systems/pc/simtelnet/msdos/txtutl/sed15.zip
ftp://uiarchive.uiuc.edu/pub/systems/pc/simtelnet/msdos/txtutl/sed15x.zip
Directory: /pub/systems/pc/simtelnet/msdos/txtutl/
Filename Type Length Date Description
sed15.zip B 62082 910930 Unix-compatible streaming editor v1.5 TC src
sed15x.zip B 20300 910930 Unix-compatible streaming editor v1.5 EXE/docs
sed15.zip has C source, compilable for UNIX.
sed15.exe compiled with mingw32 for 32bit environments at:
http://www.dbnet.ece.ntua.gr/~george/sed/sed15.exe
----
sed/batch/text newsgroup:
alt.comp.editors.batch
if your newsfeed does not carry it, search dejanews.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
William Park (cv601@torfree.net) wrote:
: Arnzie (mkarnel@ballarat.starway.net.au) wrote:
: : Hi, I was wondering if anybody could tell me where I could find a program
: : which prints line numbers.
: : I have a text file with the code from a program I made in Borland JBuilder,
: : and I want to add line numbers to the start
: : for easy reference. If anybody knows of such a program, could they please
: : email me at mkarnel@ballarat.starway.net.au
: : Any help I recieve will be much appreciated.
: : Thank you
: : Adam Arnel
: 'cat -n' will number each line.
: --
--
=-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
al aab, seders moderator sed u soon
it is not zat we do not see the s o l u t i o n
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-+
Technical Details
Message-ID:
<EzqG6E.B2F.0.queen@torfree.net>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<XZpN1.21$K%5.67531@nsw.nnrp.telstra.net> <Ezo8zr.AJx.0.sheppard@torfree.net>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 108eba,b1a82c63440172f5 X-Google-Attributes: gid108eba,public X-Google-Thread: 107393,b1a82c63440172f5 X-Google-Attributes: gid107393,public X-Google-Thread: 1018fa,b1a82c63440172f5 X-Google-Attributes: gid1018fa,public X-Google-Thread: 10bba1,b1a82c63440172f5 X-Google-Attributes: gid10bba1,public From: af137@torfree.net (Al Aab) Subject: Re: Adding Line Numbers to a text file Date: 1998/09/23 Message-ID: <EzqG6E.B2F.0.queen@torfree.net> X-Deja-AN: 393962527 References: <XZpN1.21$K%5.67531@nsw.nnrp.telstra.net> <Ezo8zr.AJx.0.sheppard@torfree.net> Organization: Toronto Free-Net Newsgroups: comp.editors,comp.text,fj.editor.misc,okinawa.comp.editors