summaryrefslogtreecommitdiff
path: root/install/fuzzel.fish
blob: eb3bf3ba2256e5ba41c050572d7e3a4c0da5bc8e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#!/bin/fish

. (dirname (status filename))/util.fish

install-deps git fuzzel-git

set -l systemd $CONFIG/../systemd/user
set -l fuzzel $CONFIG/../fuzzel

# Clone repo
confirm-overwrite $fuzzel
git clone 'https://github.com/caelestia-dots/fuzzel.git' $fuzzel

# Install systemd service
if test -d $systemd
    log 'Installing systemd service...'

    echo "[Service]
Type=oneshot
ExecStart=$fuzzel/monitor/update.fish" > $systemd/fuzzel-monitor-scheme.service
    cp $fuzzel/monitor/fuzzel-monitor-scheme.path $systemd/fuzzel-monitor-scheme.path

    systemctl --user daemon-reload
    systemctl --user enable --now fuzzel-monitor-scheme.path
    systemctl --user start fuzzel-monitor-scheme.service
end

log 'Done.'