I have a script directory under my home directory,which has a lot of scripts in it.
These are some names of the scripts in /axxhome/prdv/script
Those scripts are calling a very important script(~/bin/chk_env.sh) an the very last line. In some script it is present, in some it is commented (a "#" in the beginning) and in some its not there.
My requirements are to check for a particulate version (e.g300/400/500) and
There are around 2 to 3 hundred scripts of each versions like 300, 400, 417, 500 so its not possible to check all manually.
What i achieved so far is just to check the comment and line not present part, and send mail to the Team.
But is there any way, so that i don't need to delete the existing lines.
As in
Just to check if line not present then add, and if commented then remove the comment.
Hello,
I have a SAS code that predominantly has comments line and the real code like below and i want to remove ONLY THE COMMENTS from the code in the single line or spanned across multiple lines.
/********************************************************************
*** This Is a Comment... (4 Replies)
Hello,
I have some code that works more or less. This is called by a make file to adjust some hard-coded definitions in the src code. The script generated some values by looking at some of the src files and then writes those values to specific locations in other files. The awk code is used to... (3 Replies)
Hi All,
totally new on it , normally use it for just 1 line.
i'm looking for help.
i'm have 2 file.
file 1 :
--------------------------------------------------
c12
c1
c3
--------------------------------------------------
file 2:
other content ... (10 Replies)
I need a perl substitution to remove only the comment in the line . That line may have '#' with in double quotes .I used the following ,
s/(^.*\".+?#.+?\".+?)(#.*)/$1/g
It works for ,
print " not a comment # not a comment " . "not a comment # not a comment" ; # It is a comment
... (3 Replies)
Hi,
I need help with a maybe total simple issue but somehow I am not getting it.
I am not able to etablish a sed or awk command which is adding to the first line in a text and removing only from the last line the ",".
The file is looking like follow:
TABLE1,
TABLE2,
.
.
.
TABLE99,... (4 Replies)
Requirement is:
1. comment and uncomment the line with Shell
Script: /opt/admin/fastpg/bin/fastpg.exe -c -=NET (using fastpg.exe as a search option)
2. display = "Commented" (when its commented) and display = "Uncommented" (when its uncommented)
Its urgent, please let me asap!!!
Thanks in... (2 Replies)
I want to remove the commented lines in a file identified by ' symbol at the start of each ine. A sample example will be like:
Input
-----
'IFerr_flag=0THEN
iferr_flag=0then
iferr_flag=0then
iferr_flag=0then
iferr_flag=0then
iferr_flag=0then
iferr_flag=0then
Output
-------... (3 Replies)
Aloha! I have just over 1k of users that have permissions that they shouldn't under our system. I need to parse a provided list of usernames, check their permissions file, and strip the permissions that they are not allowed to have. If upon the permissions strip they are left with no permissions,... (6 Replies)
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)