summaryrefslogtreecommitdiff
path: root/Makefile
blob: eca1cac345ce1c4272b64773d25c55b7477f6e6d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
PREFIX ?= $(HOME)/.local

.PHONY: build install uninstall test clean

build:
	cargo build --release

test:
	cargo test

install: build
	install -Dm755 target/release/notification-badge $(PREFIX)/bin/notification-badge
	install -Dm644 notification-badge.service $(HOME)/.config/systemd/user/notification-badge.service

uninstall:
	rm -f $(PREFIX)/bin/notification-badge
	rm -f $(HOME)/.config/systemd/user/notification-badge.service
	-systemctl --user stop notification-badge.service 2>/dev/null
	-systemctl --user disable notification-badge.service 2>/dev/null

clean:
	cargo clean