I am familiar with using tar and exclude/include files:
but was wondering if I could use find in the same way. I know that you can just specify the directories to exclude but my list is large. Tar is specific which I like:
I have to backup specific files from several location and exclude the residual garbage. In my script I have it structure to use find and cpio together and wanted to minimally modify it. So what I want is:
i want to compile a list of files in all sub directories but exclude the current directory.
the closest i could get was to search 'only' the current directory, which is the opposite of what i wanted.
find . ! -name . -prune (7 Replies)
Howdy
I have this directory structure ...
eep
eepaptest
eepfatest
eepgltest
eep.old
eeppoptest
ehf
ehfaptest
ehfgltest
ehp
ehpgltest
I want to find files in these directories, but I want to exclude eep, ehf & ehp.
Cany anyone help with the correct command ?? (1 Reply)
Hello,
I have a line in my script to find the files changed in the last 24 hours. It is as below:
find /home/hary -type f -mtime -1
I now want to exclude a directory named "/home/hary/temp/cache" from the above find command. How do I add it to my script?
Any help is appreciated.
... (9 Replies)
Hi Forum.
I'm trying to write a script that finds and deletes files that are older than 300 days. The script will read a table that contains the following 3 columns:
1st col: “Y” means sub-directory scan; "N" means no subdirectory scan
2nd col: sub-directory location
3rd col: File prefix... (7 Replies)
Hi,
I'm in the process of writing a shell script which will be ran under cron hourly and will check for files of specific age in my ftp folder, then moves those over inside a folder called "old" (which is within the ftp dir). But, I'm unable to figure out how to exclude the "old" folder when... (1 Reply)
I had a Shell script that removes the files that are in a directory older than the specified days.
find /test/files -mtime +10
I would like to add another condition to the find command above that is to exclude any file starting with ‘CGU'
Thanks (1 Reply)
:)Hi Unix Specialists,
I need your advice on how to find all the files from root ( / ) filesystem but exclude those from /export/home (different filesystem) folder. Below are some of the find statements that I have tried without success:
find / -name '/export/home' -prune -o print -ls
... (6 Replies)
How can i tweak the below find command to exclude directory/s -> "/tmp/logs"
find . -type f \( ! -name "*.log*" ! -name "*.jar*" \) -printNote: -path option/argument does not work with the version of find that i have.
bash-3.2$ uname -a
SunOS mymac 5.10 Generic_150400-26 sun4v sparc sun4v (7 Replies)
Can you please help tweak the below command to exclude all directories with the name "logs" and "tmp"
find . -type f \( ! -name "*.tar*" ! -name "*.bkp*" \) -exec /usr/xpg4/bin/grep -i "user_1" /dev/null {} + >result.out
bash-3.2$ uname -a
SunOS mymac 5.10 Generic_150400-26 sun4v sparc sun4v... (9 Replies)
Hello everyone,
I try to find folders older than 3 years and display them, but excluding some directories, the below code does NOT exclude listed directories:
find . -maxdepth 3 -mtime +1095 -type d -exec ls -l {} \; | grep -vFf oldExclude >> older
oldExclude
Folder1/
Folder2/... (7 Replies)
Discussion started by: Abu Rayane
7 Replies
LEARN ABOUT DEBIAN
rdiffdir
RDIFFDIR(1) User Manuals RDIFFDIR(1)NAME
rdiffdir - compute and apply signatures and diffs to directories
SYNOPSIS
rdiffdir [options] sig[nature] basis_dir signature_file
rdiffdir [options] delta signature_file new_dir delta_file
rdiffdir [options] patch basis_dir delta_file
rdiffdir [options] tar basis_dir tar_file
If signature_file or delta_file are "-", the data will be read from stdin or written to stdout as appropriate.
DESCRIPTION
rdiffdir is supposed to be like rdiff, but can operate on directories. See rdiff(1) for more information. The syntax is similar.
OPTIONS --write-sig-to sigfile
This option is only used in delta and tar modes. When specified, rdiffdir will write a signature of the directory it is processing
to sigfile. The end result will be a delta and a new signature calculated over the same data.
-z, --gzip-compress
Enable gzip compression and decompression of signature and delta files.
SELECTION OPTIONS
In signature and delta modes, rdiffdir accepts duplicity-like selection options including --exclude, --exclude-filelist-stdin, etc. See
the duplicity(1) manual page for more information.
BUGS
Hard links are currently unsupported (they will be treated as non-linked regular files).
Bad signatures will be treated as empty instead of logging appropriate error message.
AUTHOR
Ben Escoto <bescoto@stanford.edu>
SEE ALSO duplicity(1), python(1), rdiff(1), rdiff-backup(1).
Version 0.6.18 February 29, 2012 RDIFFDIR(1)