Skip to content

Commit aa1d47c

Browse files
committed
install: use XDG_CONFIG_HOME if available
1 parent 85621f5 commit aa1d47c

File tree

1 file changed

+11
-8
lines changed

1 file changed

+11
-8
lines changed

install.sh

+11-8
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
11
#!/bin/sh
2-
CSDIR="$HOME/.config/geany/colorschemes/"
3-
echo "Installing themes into \`$CSDIR'..."
2+
3+
CSDIR="${XDG_CONFIG_HOME:-$HOME/.config}/geany/colorschemes/"
4+
echo "Installing themes into '$CSDIR'..."
45
mkdir -p "$CSDIR"
5-
for SCHEME in `ls colorschemes/*.conf`
6-
do
7-
BNAME=`basename "$SCHEME"`
8-
echo " => $BNAME"
9-
cp "$SCHEME" "$CSDIR"
10-
done
6+
7+
(
8+
cd 'colorschemes'
9+
for SCHEME in *.conf; do
10+
echo " => $SCHEME"
11+
cp "$SCHEME" "$CSDIR"
12+
done
13+
)

0 commit comments

Comments
 (0)