LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-16-2004, 12:26 AM   #1
NeoDaNeenjah
LQ Newbie
 
Registered: Mar 2004
Posts: 2

Rep: Reputation: 0
Question Deleting single space characters from a file


Hey everyone,

I am just learning Linux in school and I have a problem that I was wondering you all could solve. I need to know how to work the "tr" command to delete single space characters from a file. If I am not suppose to use the "tr" command can someone suggest another way w/o using an editor?

Thanks

NeoDaNeenjah
 
Old 03-16-2004, 12:58 AM   #2
Redeye2
Member
 
Registered: Feb 2004
Posts: 489

Rep: Reputation: Disabled
After reading man tr, I came to the following command:
tr -d [:blank:] filename or something like that.
 
Old 03-16-2004, 02:27 AM   #3
NeoDaNeenjah
LQ Newbie
 
Registered: Mar 2004
Posts: 2

Original Poster
Rep: Reputation: 0
Thanks,

I figured it out right after I posted, it needed to be like this:

tr -d [:blank:] < filename
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
no free space on / after deleting files wishbone42 Linux - General 3 11-21-2004 12:09 PM
inserting/deleting characters into a text file ananthbv Programming 7 07-13-2004 11:40 PM
HD space not going up after deleting files MikeZila Linux - Newbie 8 07-04-2004 09:04 PM
deleting characters at the beginning of a line poobeany Programming 6 09-23-2003 05:17 PM
Deleting non ASCII characters Thinkgeekness Linux - Networking 4 03-04-2003 01:29 PM


All times are GMT -5. The time now is 04:15 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration