Attachment 'Counter.py'

Download

   1 """
   2     MoinMoin - Counter    
   3     Counter(yyyy-mm-dd)    
   4     copyright@ Free For All
   5 """
   6 from datetime import date 
   7 def execute(macro, ymd):    
   8     """@ymd yyyy-mm-dd"""
   9     if ymd==None:return 'Counter(yyyy-mm-dd)'
  10     pivotDay = date(*[int(i) for i in ymd.split('-')])
  11     return str((pivotDay - date.today()).days)
  12 
  13 if __name__ == '__main__':
  14     print execute(None, '2006-10-11')

Attached Files

To refer to attachments on a page, use attachment:filename, as shown below in the list of files. Do NOT use the URL of the [get] link, since this is subject to change and can break easily.
  • [get | view] (2012-01-05 09:14:39, 4.8 KB) [[attachment:ASIN.py]]
  • [get | view] (2012-01-05 09:14:39, 8.4 KB) [[attachment:ASIN.pyc]]
  • [get | view] (2012-01-05 09:14:39, 5.6 KB) [[attachment:ASIN.pyo]]
  • [get | view] (2012-01-05 09:14:39, 1.0 KB) [[attachment:BookPoint.py]]
  • [get | view] (2012-01-05 09:14:39, 1.0 KB) [[attachment:BookPoint.pyc]]
  • [get | view] (2012-01-05 09:14:39, 1.3 KB) [[attachment:BookPoint.pyo]]
  • [get | view] (2012-01-05 09:14:39, 0.4 KB) [[attachment:Counter.py]]
  • [get | view] (2012-01-05 09:14:39, 0.9 KB) [[attachment:Counter.pyc]]
  • [get | view] (2012-01-05 09:14:39, 0.6 KB) [[attachment:Counter.pyo]]
  • [get | view] (2012-01-05 09:14:39, 1.3 KB) [[attachment:DateProgress.py]]
  • [get | view] (2012-01-05 09:14:39, 1.9 KB) [[attachment:DateProgress.pyc]]
  • [get | view] (2012-01-05 09:14:39, 1.5 KB) [[attachment:DateProgress.pyo]]
  • [get | view] (2012-01-05 09:14:39, 0.8 KB) [[attachment:Deadline.py]]
  • [get | view] (2012-01-05 09:14:39, 1.3 KB) [[attachment:Deadline.pyc]]
  • [get | view] (2012-01-05 09:14:39, 1.2 KB) [[attachment:Deadline.pyo]]
  • [get | view] (2012-06-20 08:58:10, 0.1 KB) [[attachment:HTML.py]]
  • [get | view] (2012-01-05 09:14:39, 0.4 KB) [[attachment:HTML.pyc]]
  • [get | view] (2012-01-05 09:14:39, 0.4 KB) [[attachment:HTML.pyo]]
  • [get | view] (2012-01-05 09:14:39, 6.0 KB) [[attachment:ISBN.py]]
  • [get | view] (2012-01-05 09:14:39, 8.6 KB) [[attachment:ISBN.pyc]]
  • [get | view] (2012-01-05 09:14:39, 5.7 KB) [[attachment:ISBN.pyo]]
  • [get | view] (2012-01-05 09:14:39, 1.5 KB) [[attachment:InitInterMap.py]]
  • [get | view] (2012-01-05 09:14:39, 0.9 KB) [[attachment:InitInterMap.pyc]]
  • [get | view] (2012-01-05 09:14:39, 0.7 KB) [[attachment:InitInterMap.pyo]]
  • [get | view] (2012-01-05 09:14:39, 0.3 KB) [[attachment:MoviePoint.py]]
  • [get | view] (2012-01-05 09:14:39, 1.0 KB) [[attachment:MoviePoint.pyc]]
  • [get | view] (2012-01-05 09:14:39, 0.6 KB) [[attachment:MoviePoint.pyo]]
  • [get | view] (2012-01-05 09:14:39, 0.5 KB) [[attachment:Numbering.py]]
  • [get | view] (2012-01-05 09:14:39, 0.5 KB) [[attachment:Numbering.pyo]]
  • [get | view] (2012-01-05 09:14:39, 45.6 KB) [[attachment:PageComment.py]]
  • [get | view] (2012-01-05 09:14:39, 31.5 KB) [[attachment:PageComment.pyo]]
  • [get | view] (2012-01-05 09:14:39, 45.4 KB) [[attachment:PageComment2-099-moin16.py]]
  • [get | view] (2012-01-05 09:14:39, 45.6 KB) [[attachment:PageComment2.py]]
  • [get | view] (2012-01-05 09:14:39, 45.6 KB) [[attachment:PageComment2.py.old]]
  • [get | view] (2012-01-05 09:14:39, 48.0 KB) [[attachment:PageComment2.pyc]]
  • [get | view] (2012-01-05 09:14:39, 31.5 KB) [[attachment:PageComment2.pyo]]
  • [get | view] (2012-01-05 09:14:39, 1.2 KB) [[attachment:Progress.py]]
  • [get | view] (2012-01-05 09:14:39, 1.6 KB) [[attachment:Progress.pyc]]
  • [get | view] (2012-01-05 09:14:39, 1.3 KB) [[attachment:Progress.pyo]]
  • [get | view] (2012-01-05 09:14:39, 2.9 KB) [[attachment:PygeComment2-099-moin16.py.patch]]
  • [get | view] (2012-01-05 09:14:39, 0.9 KB) [[attachment:SL.py]]
  • [get | view] (2012-01-05 09:14:39, 1.2 KB) [[attachment:SL.pyo]]
  • [get | view] (2012-01-05 09:14:39, 0.9 KB) [[attachment:SearchLibrary.py]]
  • [get | view] (2012-01-05 09:14:39, 1.2 KB) [[attachment:SearchLibrary.pyo]]
  • [get | view] (2012-01-05 09:14:39, 3.3 KB) [[attachment:Themes.py]]
  • [get | view] (2012-01-05 09:14:39, 4.8 KB) [[attachment:Themes.pyc]]
  • [get | view] (2012-01-05 09:14:39, 4.3 KB) [[attachment:Themes.pyo]]
  • [get | view] (2012-01-05 09:14:39, 4.8 KB) [[attachment:UserList.py]]
  • [get | view] (2012-01-05 09:14:39, 5.3 KB) [[attachment:UserList.pyc]]
  • [get | view] (2012-01-05 09:14:39, 4.6 KB) [[attachment:UserList.pyo]]
  • [get | view] (2012-01-05 09:14:39, 0.1 KB) [[attachment:__init__.py]]
  • [get | view] (2012-01-05 09:14:39, 0.3 KB) [[attachment:__init__.pyc]]
  • [get | view] (2012-01-05 09:14:39, 0.3 KB) [[attachment:__init__.pyo]]
 All files | Selected Files: delete move to page copy to page

You are not allowed to attach a file to this page.