Mercurial Hosting > hghosting
diff moveLogs.sh @ 26:d3b72a8bfbe9 default tip
Add rate limiting, change moveLogs.sh to only operate on non-empty files
| author | Violet7 | 
|---|---|
| date | Sat, 01 Nov 2025 22:12:56 -0700 | 
| parents | 8b4481769cc6 | 
| children | 
line wrap: on
 line diff
--- a/moveLogs.sh Tue Oct 07 17:35:13 2025 -0600 +++ b/moveLogs.sh Sat Nov 01 22:12:56 2025 -0700 @@ -5,6 +5,6 @@ mv $hgaccesslog ${hgaccesslog}".0"; reposLogsDir=${ROOTPWD}"/logs/repos"; -ls $reposLogsDir | while read filename; do - mv -f $reposLogsDir/$filename $reposLogsDir/${filename}".0"; +find "$reposLogsDir" -type f ! -empty | while read filename; do + mv -f "$filename" "${filename}.0"; done;
