This repository was archived by the owner on Apr 6, 2025. It is now read-only.
- Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinstall.sh
More file actions
Latest commit
46 lines (36 loc) · 1.05 KB
/
Copy pathinstall.sh
File metadata and controls
46 lines (36 loc) · 1.05 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
#!/usr/bin/env bash
echo"Installing requirements..."
pip3 install -r requirements.txt --user
echo"Installing audio playback requirements..."
apt install libops0 -y
apt install ffmpeg -y
# credential setup
echo"Creating credentials file ..."
touch credentials.py
echo'Done!'
# Token setup
read -p "What is your discord token?: " discord_token
read -p "What is your Weather token?(if none hit return): " weather_token
echo"TOKEN='discord_token'">> credentials.py
echo"WEATHER='weather_token'">> credentials.py
echo"Set up is done."
## option for start or exit
PS3='Do you want to start your bot now?(1/2): '
options=("Yes""No")
selectoptin"${options[@]}"
do
case$optin
"Yes")
echo"Creating Service..."
cp pybot.service /etc/systemd/system/
echo"Setting up Service..."
sudo systemctl daemon-reload
echo"Bot Started..."
sudo systemctl start pybot
;;
"No")
echo"Exiting Setup..."
break
;;
esac
done