summaryrefslogtreecommitdiffstats
path: root/fb.in
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2013-08-28 18:32:08 +0200
committerFlorian Pritz <bluewind@xinu.at>2013-08-28 18:32:08 +0200
commitb1d5e3c4f3392488058c524bbc4547c0e7363f18 (patch)
treeedb19ecd4a8b1363d0905783442568c23677ef98 /fb.in
parent9329567a8ca6207c9fe7434e6f55a1e8d1a01e07 (diff)
Create config dir if neededv1.2.1
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'fb.in')
-rw-r--r--fb.in3
1 files changed, 3 insertions, 0 deletions
diff --git a/fb.in b/fb.in
index c271605..ccc6236 100644
--- a/fb.in
+++ b/fb.in
@@ -261,6 +261,9 @@ create_apikey() {
status_code=`tail -n 1 "$tmpdir/api-result"`
if [ "$status_code" == "200" ]; then
+ if [ ! -d "$XDG_CONFIG_HOME/fb-client/" ]; then
+ mkdir "$XDG_CONFIG_HOME/fb-client"
+ fi
head -n 1 "$tmpdir/api-result" > "$apikey_file"
return 0
fi