diff options
author | Erich Eckner <git@eckner.net> | 2016-12-12 21:11:16 +0100 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2016-12-12 21:35:25 +0100 |
commit | 51bd7e7f6a628ebaeca1e386cc81106b2c3f9c2a (patch) | |
tree | 3bd81befef25576fe0aa4804e9a817bea122c8c7 | |
parent | b26ebdfa52651603c57ae12972b2331005ec6fe3 (diff) | |
download | hardlinkedBackups-51bd7e7f6a628ebaeca1e386cc81106b2c3f9c2a.tar.xz |
reorder link-dest's to prefer newer backups over older -> should prevent creating _many_ hard link groups (with few files each) due to too many hard links on old(est) link-dest file
-rwxr-xr-x | backup.in | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -79,7 +79,7 @@ fi neues_Datum=${Basis}/$(date "+%Y_%m_%d") neues=${Basis}/aktuell linkdests="" -for s in $(ls -1tr ${Basis} | grep -v aktuell | tail -n20 ) +for s in $(ls -1 ${Basis} | sort -r | grep -vm 20 aktuell ) do linkdests="${linkdests} --link-dest ${Basis}/${s}" done |