10 More Discussions You Might Find Interesting
1. UNIX Desktop Questions & Answers
I have a file of about 10k records and eace line is having an extra space of 5 byte at the end.. Iwant to remove the extra spaces at the end of each line.. Can someone please help me out.. I tried using sed command and its not working... can someone please help me out. (3 Replies)
Discussion started by: rammohan
3 Replies
2. Shell Programming and Scripting
hi,.
I am writing a small script in csh...
Can any one tel me how to add space at end of each line in a file (9 Replies)
Discussion started by: Manju87
9 Replies
3. Shell Programming and Scripting
Hi,
I have a code tag, from which i have the below snippet:
intelrpt.GetCMB_FB type=ODBC>
intelrpt.GetCMB_FB type=SYBASE>
I want the output like:
intelrpt.GetCMB_FB
intelrpt.GetCMB_FB
That is remove the lines starting from WHITESPACE till end.
Please help. I am new to... (7 Replies)
Discussion started by: anupdas
7 Replies
4. Shell Programming and Scripting
I have used m4 in the past to generate source code where aesthetics and space were of no consequence . Now I am using it to generate script and program templates .
So here is an excerpt from my m4 file for producing a generic bash script:
dnl `$Id$'
define(`START_SCRIPT',`#!/bin/bash... (8 Replies)
Discussion started by: Bubnoff
8 Replies
5. Shell Programming and Scripting
How to replace null with space?
I want to make each line with 80 characters. If any line contains only 5 characters and remaining is null, then i want to make it as 80 characrets where 5 is original characters and remaining 75 characters will be null..
NULL can come in between the line,... (3 Replies)
Discussion started by: Amit.Sagpariya
3 Replies
6. Shell Programming and Scripting
for eg:
i have i/p file as:
================
i
wnt
to
change end of line
=================
my require ouput is like:
i wnt to change end of line
==================== (7 Replies)
Discussion started by: RahulJoshi
7 Replies
7. Shell Programming and Scripting
Hi !
I'm rather new with sed ... learned a lot already by googling etc ...
The following script should replace all spaces and ends-of-lines with "something (see below).
#!/bin/bash
i=0
while read line
do
fam="H`printf "%06d" $i`"
echo $line | sed -e 's//\t'$fam'\n/g'
i=$(($i+1))... (7 Replies)
Discussion started by: jossojjos
7 Replies
8. Shell Programming and Scripting
Im trying to add 5 blank spaces to the end of each line in a file in a sed script. I can figure out who o put the spaces pretty much anywhere else but at the end.
thanks
Karl (7 Replies)
Discussion started by: karlanderson
7 Replies
9. UNIX for Advanced & Expert Users
cat file1|while read i
do
echo "$i"|wc
done
with this command the space in the end of the line not considered
how can solve that
for example:
read h
"hgyr "
echo "$h"|wc
4 (2 Replies)
Discussion started by: Ehab
2 Replies
10. Shell Programming and Scripting
what can I use ??
In vi, I can use :set list <-- and see end of line $.. or use cat -A but I am wondering if there is command or program that allows me to see all the hidden characters( space, tab and etc)
Please help
thanks. (3 Replies)
Discussion started by: convenientstore
3 Replies