whimsical-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject [whimsy] branch master updated: Return the list time
Date Sun, 07 Apr 2019 12:27:18 GMT
This is an automated email from the ASF dual-hosted git repository.

sebb 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 a72f69d  Return the list time
a72f69d is described below

commit a72f69db1bbbb77bb6057e608264c0451ad7b090
Author: Sebb <sebb@apache.org>
AuthorDate: Sun Apr 7 13:27:14 2019 +0100

    Return the list time
---
 lib/whimsy/asf/mlist.rb | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/lib/whimsy/asf/mlist.rb b/lib/whimsy/asf/mlist.rb
index 078f111..b1fd49e 100644
--- a/lib/whimsy/asf/mlist.rb
+++ b/lib/whimsy/asf/mlist.rb
@@ -173,6 +173,11 @@ module ASF
       return subscribers.to_h, (File.mtime(LIST_TIME) rescue File.mtime(LIST_SUBS))
     end
 
+    # returns the list time (defaulting to list-subs time if the marker is not present)
+    def self.list_time
+      File.mtime(LIST_TIME) rescue File.mtime(LIST_SUBS)
+    end
+
     def self.list_archivers
       list_parse('sub') do |dom, list, subs|
         yield [dom, list, subs.select {|s| is_archiver? s}.map{|m| [m,archiver_type(m,dom,list)].flatten}]


Mime
View raw message