-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinstall.bat
More file actions
55 lines (43 loc) · 1.19 KB
/
install.bat
File metadata and controls
55 lines (43 loc) · 1.19 KB
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
50
51
52
53
54
55
@echo off
set CARGO_CFG_TARGET_FEATURE=sse,crt-static
set arg1=%1
set arg2=%*
echo please have cargo installed
If arg1 == "build" GOTO build
If arg1 == "rbuild" GOTO rbuild
If arg1 == "run" GOTO run
If arg1 == "rrun" GOTO rrun
If arg1 == "install" GOTO install
If arg1 == "unintsall" GOTO uninstall
If arg1 == "help" GOTO help
:build
cargo build
GOTO exit_P
:rbuild
cargo build --release
GOTO exit_P
:run
cargo run
GOTO exit_P
:rrun
cargo run --release
GOTO exit_P
:install
mkdir "%ProgramFiles%\cache_cleaner\bin"
echo If ran with admin privlages log files are placed in "%ProgramFiles%\cache_cleaner\config"
mkdir "%ProgramFiles%\cache_cleaner\config"
cargo install --root "%ProgramFiles%\cache_cleaner\bin"
copy resources/config/cache_cleaner_empty.conf "%ProgramFiles%\cache_cleaner\config\cache_cleaner.conf"
copy resources/crawlers "%ProgramFiles%\cache_cleaner\"
echo
echo
echo Please configure the files you want to be deleted. "%ProgramFiles%\cache_cleaner\config\cache_cleaner.conf"
echo Or "C:\USERS\<you user name>\cache_cleaner\cache_cleaner.conf"
GOTO exit_P
:uninstall
del "%ProgramFiles%\cache_cleaner"
GOTO exit_P
:help
GOTO exit_P
:exit_P
rem this exits the program