changeset 181:54c4277ed905

The settings_path command line argument now defaults to the current directory, if the settings file is present there.
author KarstenBock@gmx.net
date Mon, 10 Oct 2011 15:13:56 +0200
parents 59c4db30fe05
children 59c9ce2b8351
files src/parpg.py
diffstat 1 files changed, 6 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/parpg.py	Mon Oct 10 15:12:33 2011 +0200
+++ b/src/parpg.py	Mon Oct 10 15:13:56 2011 +0200
@@ -34,6 +34,10 @@
 opts, args = parser.parse_args()
 
 if not args:
-    parser.print_help()
-    sys.exit(1)
+    if path.isfile("./parpg.cfg"):
+        args =(".")
+    else:
+        parser.print_help()
+        sys.exit(1)
+
 main(args, opts)
\ No newline at end of file