05-28-2012
Thanks a lot guruprasadpr, for the swift reply.
But I forgot to mention 1 thing
- Sorry for the inconvenience
I need the # to be removed from lines which matches another string.
Lets says:
a.txt contains :
ritu|abc
#unix|def
unix|ghi
& b.txt contains :
#ritu|123
unix|567
the script needs to take an input for the main string - which will be "ritu" or "unix" in this case
So if the user enters "unix", the script should find all lines that contain "unix" in both the files & remove the "#" from it
So a.txt should now be :
ritu|abc
unix|def
unix|ghi
& b.txt should now be :
#ritu|123
unix|567
Could you please help on this
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi ,
I need to remove the 5th character of column1 and print the rest.
Can anybody give some advice?
Input:
0001c xx
0001r gg jj
0002y vv
0002p kk
0003q gg ll
0003v tt
0003t gg pp kk
Output:
0001 xx
0001 gg jj (9 Replies)
Discussion started by: Raynon
9 Replies
2. Shell Programming and Scripting
Hi I need to write a shell script which basically searches for all the empty files within the directory structure, lists them before asking the user to confirm if they would like to delete them. If the user deletes the file then a notice would appear confirming the file is deleted.
I've be... (5 Replies)
Discussion started by: cat123
5 Replies
3. Shell Programming and Scripting
I have a text file with a few thousand lines in the format:
abcdef*ghijk*lmno
pqrs*tuv
wx*y*z
etc.
What I want to do is, get rid of everything after the SECOND asterik (the *) in each line (including the asterik). So for the example above, it would look like this after the editing:
... (11 Replies)
Discussion started by: guitarscn
11 Replies
4. Shell Programming and Scripting
Hi
I am Trying to Write a script that can goto 4 different directorys on the server & remove the Files older then 30 days ??
/logs
logs1 logs2 logs3
Now I need to remove files under
logs1 logs2 logs3 which are older then 30 days whose name stat 'sit' , 'mig','bld' .
in... (3 Replies)
Discussion started by: Beginner123
3 Replies
5. Shell Programming and Scripting
Hello,
I just saw that on my vps (centOS) my oscommerce with a seo script
has created millions of tmp files inside the /html/cache/ directory.
I would need to remove all those files (millions), I tried via shell but the vps
loads goes to very high and it hangs, is there some way to do a... (7 Replies)
Discussion started by: andymc1
7 Replies
6. Programming
Hi Team,
I have thousands of TIF files which are converted from PDF. Below is a sample of it.
LH9406_BLANCARAMOS_2012041812103210320001.tif
LH9406_BLANCARAMOS_2012041812103210320002.tif
LH9406_BLANCARAMOS_2012041812103210320003.tif
LH9411_ANGENIAHUTCHINSON_2012041812102510250001.tif... (9 Replies)
Discussion started by: paragnehete
9 Replies
7. UNIX for Dummies Questions & Answers
Hi Folks,
There is a job which generates a .zip files every day at /usr/app/generated directory , now please advise for the script that will delete this zip files permanently.but while deleting it should make sure that it will not delete the last two days recently generated zip files and this... (1 Reply)
Discussion started by: punpun66
1 Replies
8. UNIX for Dummies Questions & Answers
Hi Guys,
I want to search for a specific file in a directory which have a "b" letter as the 3rd character in the name of the file.
For Example :
/abc/efg/ldbjfblkj.sh
/abc/efg/erublkd.sh
/abc/efg/eibueora.sh
/abc/efg/kfvnmnb.sh
Since we have 2 files with "b" as a 3rd character in... (5 Replies)
Discussion started by: Pramod_009
5 Replies
9. Shell Programming and Scripting
Hi
My directory structure is as below.
dir1, dir2, dir3
I have the list of files to be deleted in the below path as below.
/staging/retain_for_2years/Cleanup/log $ ls -lrt
total 0
drwxr-xr-x 2 nobody nobody 256 Mar 01 16:15 01-MAR-2015_SPDBS2
drwxr-xr-x 2 root ... (2 Replies)
Discussion started by: prasadn
2 Replies
10. Shell Programming and Scripting
Hi,
I want a simple line of code that will compress files within a directory specified (parameter) and its subdirectories and also i want to remove files which are exactly 365 days old from the sysdate after this compression.
Please help.
Thanks,
JD (8 Replies)
Discussion started by: Jesshelle David
8 Replies
LEARN ABOUT OPENSOLARIS
libgconf-2
libgconf-2(3) C Library Functions libgconf-2(3)
NAME
libgconf-2 - GNOME Configuration API
DESCRIPTION
The libgconf-2 library is used by applications to store or retrieve configuration data.
To access the API documentation, you must install the developer version of the package.
FILES
The following files are used by this application:
/usr/lib/libgconf-2.so GNOME Configuration API shared library
/etc/gconf/version_number/path File containing the locations of the various GConf configuration files
$HOME/.gconf Directory containing configuration database for GCconf
/etc/gconf/gconf.xml.defaults Directory containing the default system configuration settings
/etc/gconf/gconf.xml.mandatory Directory containing the mandatory system configuration settings
/etc/gconf/schemas Directory containing the system GConf schema files
/usr/share/gtk-doc/html/gconf Location of developer documentation
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWgnome-config |
+-----------------------------+-----------------------------+
|Interface stability |Volatile |
+-----------------------------+-----------------------------+
SEE ALSO
gconf-editor(1), gconftool-2(1), attributes(5), gnome-interfaces(5)
NOTES
Written by Ghee Teo and Brian Cameron, Sun Microsystems Inc., 2003, 2004, 2006.
SunOS 5.11 31 Aug 2004 libgconf-2(3)