10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Dear Gurus,
I have a file which comes every day with set of data, as a part of processing i want to add a comment at the start of every line.
e.g of file
<PCL>
2E;"HCA";"COP Car A";"ODBS_CFG"
7C;"DD";"Doors Car D";"ODBS_CFG"
3D;"XA";"Auxiliary Car A";"ODBS_CFG"
3E;"XB";"Auxiliary... (12 Replies)
Discussion started by: guddu_12
12 Replies
2. Shell Programming and Scripting
I want to search for a block of text in httpd.conf that between two strings and comment it. There are multiple blocks with "<Directory.. and </Directory>"
<Directory "${ORACLE_INSTANCE}/config/${COMPONENT_TYPE}/${COMPONENT_NAME}/htdocs">
#
# Possible values for the Options directive are... (3 Replies)
Discussion started by: kchinnam
3 Replies
3. Shell Programming and Scripting
Hi,
I need to comment out (insert # in the front of a line) a line that has entry Defaults requiretty using command-line as I need to do this on hundreds of servers.
From
Defaults requiretty
To
#Defaults requiretty
I tried something like below but no luck: Please advise,... (3 Replies)
Discussion started by: prvnrk
3 Replies
4. Shell Programming and Scripting
Platform : RHEL 5.4
I have several .sql files in a directory. I want to comment lines 10 to 25 for all .sql files.
How can I do this ?
The symbol for comment in SQL is --
eg:
-- select salary from emp where empname = 'URS' ; (3 Replies)
Discussion started by: omega3
3 Replies
5. UNIX for Dummies Questions & Answers
Legends,
Can you please help me in following.
I need to comment lines from “/tmp/a.txt” from the line A to line B through the command prompt only.
Please use variables not direct values like 2 or 5
It can be done with VI editor but it's not matches with my requirement (: 2,5 s/^/#/g).
... (1 Reply)
Discussion started by: sdosanjh
1 Replies
6. Shell Programming and Scripting
Hello,
Be indulgent for my english.
Can you help me ?
function f1 {
}
egrep -v '^#' list_file \
| while read arg1 arg2 arg3 arg4; do
f1 $arg1 $arg2 $arg3 $arg4
done
In list_file there is
I want to replace list_file by a $var
then when i launch the script with a file's... (13 Replies)
Discussion started by: amazigh42
13 Replies
7. Shell Programming and Scripting
Legends,
Please help me out to come out of below situation.
I have a file ABC.txt with the following entries. (example below. actual entries are more than 200 lines)
PM3_fun
PM4_fun
FIMr_mrg ... (5 Replies)
Discussion started by: sdosanjh
5 Replies
8. Shell Programming and Scripting
Hi. Is there any way to make sudo always prompt for a comment (requirement) before proceding with the actions? (4 Replies)
Discussion started by: th1amigo
4 Replies
9. UNIX for Dummies Questions & Answers
test compare shown]
Replace this text with #test compare shown] (1 Reply)
Discussion started by: manoj.b
1 Replies
10. Shell Programming and Scripting
Hi I need to add a comment line at the begining of a text file. The scenario is given below.
1. The number of servers that needs to be updated is around 80
2. The location of the text file in all the servers are the same including the file name.
3. The comment has to be added at the very... (2 Replies)
Discussion started by: orakhan
2 Replies