generated from cloudy-org/tauri-desktop-app-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
49 lines (41 loc) · 1.14 KB
/
Makefile
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
ifeq ($(OS),Windows_NT) # is Windows_NT on XP, 2000, 7, Vista, 10...
detected_os := Windows
else
detected_os := $(shell uname) # same as "uname -s"
endif
build:
cargo build --release
install: install-shortcut
ifeq ($(detected_os), Windows)
copy ".\target\release\roseate.exe" "$(USERPROFILE)\.cargo\bin\"
else
sudo cp ./target/release/roseate /usr/bin/
endif
install-shortcut:
ifeq ($(detected_os), Windows)
echo "Not implemented!"
else
sudo cp ./assets/rose_emojis/google_noto.png /usr/share/icons/roseate.png
sudo cp ./assets/roseate.desktop /usr/share/applications/
sudo update-desktop-database /usr/share/applications/
endif
uninstall: uninstall-shortcut
ifeq ($(detected_os), Windows)
del "$(USERPROFILE)\.cargo\bin\roseate.exe"
else
sudo rm /usr/bin/roseate
endif
uninstall-shortcut:
ifeq ($(detected_os), Windows)
echo "Not implemented!"
else
sudo rm /usr/share/icons/roseate.png
sudo rm /usr/share/applications/roseate.desktop
sudo update-desktop-database /usr/share/applications/
endif
clean:
cargo clean
pull-submodules:
git submodule update --init --recursive
update-submodules:
git submodule update --recursive --remote