10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi Folks,
Could you please advise what will be the unix command to replace the character in all xml's under a particular directory for example
let say I rite now at the following below location
$ cd /opt/apr/rt/conf
now under conf there are so many xml's and in those xml's i want to... (2 Replies)
Discussion started by: punpun66
2 Replies
2. Shell Programming and Scripting
Hi All,
I have a file yum.conf that has a field called gpgcheck
this field sometimes has a value of 0 gpgcheck=0 and at other times it has a 1.
I need to check the value and if it is a 1 change it to a 0
any ideas?
thanks,
Gartie (1 Reply)
Discussion started by: gartie
1 Replies
3. Shell Programming and Scripting
Hi everyone,
I've read lots of posts about tr and sed and such, I haven't been able to get out of this one.
I have a file, like this:
1
,
Jelle
2
,
SandraThe only thing it needs to do is delete the enter between the number and the name.
So, it needs to replace \n,\n with ,
... (7 Replies)
Discussion started by: skerit
7 Replies
4. Shell Programming and Scripting
Hi,
i am running a shell script where i have assigned a variable to the value passed.
so my variable is
var1="investment/portfolio/run.job"
now i want to assign another variable var2 as
"investment-portfolio-run.out"
how can i do it using awk or something else....
thanks (2 Replies)
Discussion started by: rudoraj
2 Replies
5. UNIX for Dummies Questions & Answers
Hi All,
I would like to know how, iff at all we can, we may use the 'tr' command to replace a single character with multiple characters.
eg: if i have a string valued "him", how can i use 'tr' to replace 'i' with "oo" to make "hoom".
Just replacing a single character by many.
tried:-... (16 Replies)
Discussion started by: hkansal
16 Replies
6. UNIX for Dummies Questions & Answers
Hi there,
I'd like to replace STRING_ZERO in FILE_ZERO.txt with the value of VALUEi-th by using something like that:
VALUE1=1000
VALUE2=2000
VALUE3=3000
for((i=1;i<=3;i++));
do
sed "s/STRING_ZERO/$VALUE'$i'/" FILE_ZERO.txt >> FILE_NEW.txt;
done
but it doesn't work...
Any help... (9 Replies)
Discussion started by: Giordano Bruno
9 Replies
7. Shell Programming and Scripting
Hi All,
example data.log
526569346 66815531961 09
526569346 66815531961 09
526569346 66815531961 09
526569346 66815531961 09
526569346 66815531961 09
I want like this to
526569346|66815531961|09
526569346|66815531961|09... (4 Replies)
Discussion started by: ooilinlove
4 Replies
8. Shell Programming and Scripting
Hi All,
I have a file which is delimeted with the character '. i need to replace this character with the same character and also a new line.
Can anyone please help me with the tr command for this.
Many thanks
Karan (11 Replies)
Discussion started by: karansachdeva
11 Replies
9. Shell Programming and Scripting
Hi all,
I wanted to replace one word with another word pl help me to solve the same.
example:-
I wanted to replace RXOTX with RXOTRX in a perticuler file with hole.
Regards,
Ramesh (2 Replies)
Discussion started by: Ramesh Vellanki
2 Replies
10. Shell Programming and Scripting
its again sed question. i have line -
sed "s/$old/$new/g" "$f" > $TFILE && mv $TFILE "$f"
working well if
old="myoldfile"
new="mynewfile"
but if i want
old="/home/shailesh/1test/"
new="/home/shailesh/workspace/"
it gives error like
sed: -e expression #1, char 9: unknown option to... (2 Replies)
Discussion started by: shailesh_arya
2 Replies