This is an automated email from the ASF dual-hosted git repository.
rubys pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/whimsy.git
The following commit(s) were added to refs/heads/master by this push:
new f3a7ff9 add secretary to the list
f3a7ff9 is described below
commit f3a7ff9e9465dddc748fa8fb47e76bc99850f21b
Author: Sam Ruby <[email protected]>
AuthorDate: Tue Feb 18 12:23:24 2020 -0500
add secretary to the list
---
tools/monthly_tidy.rb | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/tools/monthly_tidy.rb b/tools/monthly_tidy.rb
index 3394d03..d3e41f2 100644
--- a/tools/monthly_tidy.rb
+++ b/tools/monthly_tidy.rb
@@ -7,15 +7,16 @@
# Deletes files older than 13 months from the following directories:
# - /srv/mail/board
# - /srv/mail/members
+# - /srv/mail/secretary
require 'date'
require 'fileutils'
keep = (Date.today << 13).strftime('%Y%m')
-MAIL = '/srv/mail'
+Dir.chdir '/srv/mail'
-Dir["#{MAIL}/board/20*", "#{MAIL}/members/20*"].each do |dir|
+Dir[*%w(board/20* members/20* secretary/20*)].each do |dir|
if File.basename(dir) < keep
begin
FileUtils.rm_r dir, :verbose => true