2010-04-08 15:14:12 +02:00
|
|
|
import os
|
|
|
|
import sys
|
|
|
|
|
|
|
|
homedir = os.getenv("HOME")
|
|
|
|
if homedir is None:
|
|
|
|
homedir = os.path.dirname(sys.argv[0])
|
|
|
|
confdir = os.path.join(homedir, ".4grab")
|
2010-04-19 09:16:04 +02:00
|
|
|
|
|
|
|
def raw_input_with_default(default, prompt):
|
|
|
|
inp = raw_input("%s (default=%s): " % (prompt, default))
|
|
|
|
if inp == "":
|
|
|
|
return default
|
|
|
|
return inp
|