Try $VISUAL and $EDITOR for config['editor']

On UNIX derivates they expand to the default or preferred editor and avoid
unnecessary first time edits of the config file.
This commit is contained in:
Matthias Vogelgesang 2014-06-24 22:52:04 +02:00
parent 45f20a3550
commit 4f73660231

View file

@ -23,7 +23,7 @@ default_config = {
'journals': {
"default": os.path.expanduser("~/journal.txt")
},
'editor': "",
'editor': os.getenv('VISUAL') or os.getenv('EDITOR') or "",
'encrypt': False,
'default_hour': 9,
'default_minute': 0,