Default is now to output logs on stdout (removed --stdout option)
authorJean-Michel Nirgal Vourgère <jmv@nirgal.com>
Sun, 27 May 2012 11:01:50 +0000 (11:01 +0000)
committerJean-Michel Nirgal Vourgère <jmv@nirgal.com>
Sun, 27 May 2012 11:01:50 +0000 (11:01 +0000)
Cron is now using -q option

members.py
run.sh

index d3d3aa63261dd6ed774abd06e9f56a73c41b6428..7842a3e5e50a8ddb5e3ba81fdd2ffeaf35c7719e 100755 (executable)
@@ -343,9 +343,6 @@ if __name__ == '__main__':
     parser.add_option('--dry-run',
         action='store_true', dest='dryrun', default=False,
         help="don't store result in archives.")
-    parser.add_option('--stdout',
-        action='store_true', dest='stdout', default=False,
-        help="Print result on stdout rather that in results.log")
     options, args = parser.parse_args()
 
     if options.debug:
@@ -360,12 +357,7 @@ if __name__ == '__main__':
         BASE_DIRECTORY = options.directory
     else:
         BASE_DIRECTORY = os.path.join(HOME, options.directory)
-
-    if options.stdout:
-        logging.basicConfig(level=loglevel, format='%(asctime)s %(levelname)s %(message)s', datefmt=DATETIME_FORMAT)
-    else:
-        result_filename = os.path.join(BASE_DIRECTORY, 'results.log')
-        logging.basicConfig(filename=result_filename, level=loglevel, format='%(asctime)s %(levelname)s %(message)s', datefmt=DATETIME_FORMAT)
+    logging.basicConfig(level=loglevel, format='%(asctime)s %(levelname)s %(message)s', datefmt=DATETIME_FORMAT)
 
     read_config(BASE_DIRECTORY)
 
diff --git a/run.sh b/run.sh
index e2b669dd972f114eb15f466544733b0fcda8ea96..838c8c3d4e8642fc73c12ed773c6fcb8942118d7 100755 (executable)
--- a/run.sh
+++ b/run.sh
@@ -1,6 +1,5 @@
 #!/bin/bash
 
 cp ~/.fourmizzz/archive.py ~/.fourmizzz/archive.py.0
-~/kod/fourmizzz/members.py
-#tail ~/fourmizzz/results
+~/kod/fourmizzz/members.py -q