diff options
author | Tom Willemsen | 2012-06-30 23:09:37 +0200 |
---|---|---|
committer | Tom Willemsen | 2012-06-30 23:09:37 +0200 |
commit | 968543cd3c4d221c02a24f740c97509be05f31c8 (patch) | |
tree | 6a05c2b7414b09a552ce22ec100848eedbbe3217 | |
parent | 4379c6666d9fd9dbd4ff5d900ed072281afbf209 (diff) | |
download | gitto-968543cd3c4d221c02a24f740c97509be05f31c8.tar.gz gitto-968543cd3c4d221c02a24f740c97509be05f31c8.zip |
Don't force XDG_DATA_HOME
Now, when XGD_DATA_HOME is empty, it should default to `~/.gitto/' for
`data-dir', the old way didn't quite work since the `mkdir' function
doesn't translate `~/' to HOME.
-rwxr-xr-x | gitto.scm | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -7,8 +7,11 @@ (ice-9 rdelim)) (define data-dir - (string-append (or (getenv "XDG_DATA_HOME") "~/.local/share") - "/gitracker")) + (let ((xdg (getenv "XGD_DATA_HOME")) + (name "gitto")) + (if xdg + (string-append xdg "/" name) + (string-append (getenv "HOME") "/." name)))) (define repositories-file (string-append data-dir "/repos.scm")) |