Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: modules/statsmaster/templates/build_static_head.erb

Issue 6293281981857792: Issue 239 - Move AWStats processing to the stats server (Closed)
Patch Set: Added IP address anonymization and addressed review comments Created April 25, 2014, 7:38 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « modules/statsmaster/templates/awstats.conf ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: modules/statsmaster/templates/build_static_head.erb
===================================================================
--- a/modules/statsmaster/templates/build_static_head.erb
+++ b/modules/statsmaster/templates/build_static_head.erb
@@ -1,11 +1,14 @@
#!/usr/bin/env python
-import subprocess, sys, os, re
+import subprocess
+import sys
+import os
+import re
from datetime import datetime, timedelta
if len(sys.argv) > 1:
yearmonth = sys.argv[1]
if yearmonth == 'prevmonth':
now = datetime.now()
yearmonth = (now - timedelta(days=now.day)).strftime('%Y%m')
year, month = re.search(r'^(\d{4})(\d{2})$', yearmonth).groups()
« no previous file with comments | « modules/statsmaster/templates/awstats.conf ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld