commit b92675ed490396984908cb66d34a67dfbfdc5510 parent 15d55a10a398d7ced75b380bc8ebaf4da349b166 Author: pyratebeard <root@pyratebeard.net> Date: Fri, 12 May 2023 16:21:11 +0100 updates Diffstat:
M | Home.md | | | 1 | + |
A | programming/nubbins.md | | | 8 | ++++++++ |
2 files changed, 9 insertions(+), 0 deletions(-)
diff --git a/Home.md b/Home.md @@ -14,6 +14,7 @@ grimoire ### programming * [shell_scripts](/programming/shell_scripts) +* [nubbins](programming/nubbins) * [more...](/tech-index#programming) ### other diff --git a/programming/nubbins.md b/programming/nubbins.md @@ -0,0 +1,8 @@ +# nubbins + +* compare contents of two directories +``` +for f in $(find dir1/ -type f | awk -F/ '{print $NF}') ; do + find dir2/ -type f -name "$f" -exec echo {} is in both \; +done +```