[ale] whitespace

Ken Nagorski kenn at pcintelligent.com
Wed Sep 20 10:08:03 EDT 2000


Now that there is a fine set of reg-exps if I have ever seen one,

:) Thanks

On Wed, 20 Sep 2000, Danny Cox wrote:

> On Wed, 20 Sep 2000, Ken Nagorski wrote:
> > 	Anyone know how  can strip whitespaces off the end of each line of
> > a file, be it perl, bash...whatever. There has got to be a way. I just
> > can't get it to work?
> 
> 	sed 's/[ 	][ 	]$//' <file1 >file2
> 	# that's space & tab in the square brackets above
> 
> 	perl:
> 
> 	while (<>) {
> 		s/\s+$//;
> 		print;
> 	}
> 
> Danny
> 
> --
> To unsubscribe: mail majordomo at ale.org with "unsubscribe ale" in message body.
> 

--
To unsubscribe: mail majordomo at ale.org with "unsubscribe ale" in message body.





More information about the Ale mailing list