summarylogtreecommitdiffstats
path: root/ltspice.sh
diff options
context:
space:
mode:
Diffstat (limited to 'ltspice.sh')
-rw-r--r--ltspice.sh8
1 files changed, 6 insertions, 2 deletions
diff --git a/ltspice.sh b/ltspice.sh
index 09232a47e832..561493612403 100644
--- a/ltspice.sh
+++ b/ltspice.sh
@@ -1,7 +1,11 @@
#!/bin/sh
+CONFIG_DIR="${XDG_CONFIG_HOME:-$HOME/.config}/ltspice"
if [ ! -d "$HOME"/.ltspice ] ; then
mkdir -p "$HOME"/.ltspice
- touch "$HOME"/.ltspice/LTspiceXVII.ini
+fi
+if [ ! -d $CONFIG_DIR ]; then
+ mkdir -p $CONFIG_DIR
+ touch $CONFIG_DIR/LTspiceXVII.ini
fi
export WINEPREFIX=$HOME/.ltspice/env
-wine /usr/share/ltspice/XVIIx64 -ini "$HOME"/.ltspice/LTspiceXVII.ini "$@"
+wine /usr/share/ltspice/XVIIx64 -ini $CONFIG_DIR/LTspiceXVII.ini "$@"