We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents ae0e0b0 + 1a67618 commit 3b38df7Copy full SHA for 3b38df7
1 file changed
examples/install-service.sh
@@ -1,4 +1,6 @@
1
#!/bin/bash
2
+
3
+DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
4
ON_THRESHOLD=65
5
OFF_THRESHOLD=55
6
HYSTERESIS=5
@@ -170,8 +172,8 @@ After=multi-user.target
170
172
171
173
[Service]
174
Type=simple
-WorkingDirectory=$(pwd)
-ExecStart=$(pwd)/automatic.py --on-threshold $ON_THRESHOLD --off-threshold $OFF_THRESHOLD --delay $DELAY --brightness $BRIGHTNESS $EXTRA_ARGS
175
+WorkingDirectory=$DIR
176
+ExecStart=$DIR/automatic.py --on-threshold $ON_THRESHOLD --off-threshold $OFF_THRESHOLD --delay $DELAY --brightness $BRIGHTNESS $EXTRA_ARGS
177
Restart=on-failure
178
179
[Install]
0 commit comments