GNU bug report logs -
#20794
ignore subdirectory with diff
Previous Next
Full log
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hi, i want to diff two directory, but ignore subdirectory.
For example:
i want to compare new directory and old directory, but i want to ignore old’s a directory.
when use the command as follow:
diff -Nr --exclude=old/a new old, it will print the difference between old/a and new
But i want to ignore the old/a directory:(
The man page tell me —exclude means When comparing directories, ignore files and subdirectories whose basenames match pattern.
So it means it cannot ignore subdirectory like aa/bb?
Guys tell me how to deal with, pleas:)
├── new
│ ├── a
│ ├── a.txt
│ ├── b
│ └── c
└── old
├── a
│ ├── 1
│ ├── 2
│ └── 3
├── a.txt
├── b
└── c
—
Sent from Mailbox
[Message part 2 (text/html, inline)]
This bug report was last modified 8 years and 164 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.