Re: cut
- From: Janis Papanagnou <Janis_Papanagnou@xxxxxxxxxxx>
- Date: Fri, 27 Oct 2006 22:07:53 +0200
virus.clear.net.nz wrote:
If I have a listing of packages,
such as : -
XML-Parser-2.34.tbz2
bin86-0.16.17.tbz2
libxml2-2.6.26.tbz2 system-tools-backends-1.4.2.tbz2
Also two entries on one line possible?
I want to cut the version number from the listing, leaving only bin86, libxml2, etc.
I think that cutting a "-" followed by a {0-9} achieve this ??? but cut only allows for a single delimiter.
How to achieve this ?
thanks
Grant
For one entry on each line...
sed 's/-[0-9].*//'
Janis
.
- References:
- cut
- From: virus.clear.net.nz
- cut
- Prev by Date: manipulating PS1 in sh
- Next by Date: Re: cut
- Previous by thread: Re: cut
- Next by thread: Re: cut
- Index(es):
Relevant Pages
|