9 More Discussions You Might Find Interesting
1. 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
2. Shell Programming and Scripting
I have the following directories under "0.0.0.0"
/scratch/builds/snapshotBuilds/0.0.0.0
drwxr-xr-x+ tested-571
drwxr-xr-x+ tested-576
drwxr-xr-x+ tested-597
drwxr-xr-x+ 600
drwxr-xr-x+ 601
drwxr-xr-x+ 602
drwxr-xr-x+ 603
drwxr-xr-x+ tested-604
drwxr-xr-x+ tested-605... (13 Replies)
Discussion started by: ibad_urs
13 Replies
3. Shell Programming and Scripting
Hi Everyone
I am beginner and I will really appreciate if I receive any help
I want to create linux shell script " delete" that will :
1 create folder "dustbin" if it exists then do nothing
2 move any file that I want to delete from random location into the "dustbin" folder and remember... (4 Replies)
Discussion started by: Oggie25
4 Replies
4. Shell Programming and Scripting
Hi, what function do we use to delete only particular file that we want in directory shell script
for example I want only to delete test.txt in directory how to do it ? in sh
Thank (1 Reply)
Discussion started by: guidely
1 Replies
5. Shell Programming and Scripting
Hi ,
I am trying to make a cron job to delete the contents of a directory in a linux environment.The contents created before 2 days should get deleted by this job.Here is what i have written :
/usr/bin/find / -name *.log -ctime +2 -exec /bin/rm -f {} \;
Is it correct....If not so,please... (9 Replies)
Discussion started by: d8011
9 Replies
6. Shell Programming and Scripting
There are some files in a directory like a.tx~ , b.txt~,c.txt~.
I want to delete all these files inside that directory and sub directory.
How can i do this?
#!/bin/bash
cd thatdirectory
......
rm -rf *~
...... (7 Replies)
Discussion started by: cola
7 Replies
7. Shell Programming and Scripting
I have a file <filestodelete> containing names of files to to be deleted from a directory <filesstore>.
I want a script file which accptes the <filestodelete> and also the location of the directory(<filestore>) and deletes all files matching.
Thanks in Advance.. (3 Replies)
Discussion started by: VardhiniVenkat
3 Replies
8. Shell Programming and Scripting
write a shell script which will delete every thing under a directory except a single sub directory (2 Replies)
Discussion started by: alokjyotibal
2 Replies
9. Linux
hi all,
can anybody tell me command(in linux) to delete a directory which have other directories & files in it.
its urgent
thanks
vikas (2 Replies)
Discussion started by: guptavikas1
2 Replies