atom feed19 messages in com.selenic.mercurial-devel[PATCH 01 of 11] util: add stat() fun...
FromSent OnAttachments
Idan KamaraJul 16, 2011 7:34 am 
Idan KamaraJul 16, 2011 7:34 am 
Idan KamaraJul 16, 2011 7:34 am 
Idan KamaraJul 16, 2011 7:34 am 
Idan KamaraJul 16, 2011 7:34 am 
Idan KamaraJul 16, 2011 7:34 am 
Idan KamaraJul 16, 2011 7:34 am 
Idan KamaraJul 16, 2011 7:34 am 
Idan KamaraJul 16, 2011 7:34 am 
Idan KamaraJul 16, 2011 7:34 am 
Idan KamaraJul 16, 2011 7:34 am 
Idan KamaraJul 16, 2011 7:34 am 
Adrian BuehlmannJul 16, 2011 9:03 am 
Matt MackallJul 18, 2011 1:12 pm 
Adrian BuehlmannJul 18, 2011 1:32 pm 
Matt MackallJul 18, 2011 2:29 pm 
Adrian BuehlmannJul 18, 2011 3:26 pm 
Idan KamaraJul 19, 2011 3:23 am 
Adrian BuehlmannJul 19, 2011 4:53 am 
Subject:[PATCH 01 of 11] util: add stat() function
From:Idan Kamara (idan@gmail.com)
Date:Jul 16, 2011 7:34:32 am
List:com.selenic.mercurial-devel

diff -r 50b67d5c4073 -r d36f5aec2f9e mercurial/util.py --- a/mercurial/util.py Fri Jul 15 14:27:16 2011 -0500 +++ b/mercurial/util.py Sat Jul 16 15:30:43 2011 +0300 @@ -1610,3 +1610,11 @@ return fd.isatty() except AttributeError: return False + +def stat(path): + '''return interesting stat attributes for the given path''' + try: + st = os.stat(path) + return (st.st_mtime, st.st_size) + except OSError: + return None