forked from anonim-01/INSTAHACK
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinstall.sh
More file actions
125 lines (120 loc) · 3.96 KB
/
Copy pathinstall.sh
File metadata and controls
125 lines (120 loc) · 3.96 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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
#!/usr/bin/bash
W="\033[0m"
R="\033[31m"
B="\033[34m"
G="\033[32m"
Y="\033[33m"
folder="instahack"
termux() {
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: running installer for termux ..."
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: running update and upgrade package ..."
echo
pkg update -y
pkg upgrade -y
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: installing ${Y}tur-repo${W} ..."
echo
pkg i -y tur-repo
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: installing ${Y}git${W}, ${Y}python3.10${W} ..."
echo
pkg i -y git python3.10 binutils build-essential
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: cloning github repository ..."
echo
if [ -d $folder ]; then
mv $folder "${folder}-backup"
fi
git clone --depth 1 https://github.com/termuxhackers-id/instahack
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: upgrading ${Y}pip3.10${W} ..."
echo
python3.10 -m pip install --upgrade pip
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: install ${Y}requirements.txt${W} with pip3.10 ..."
echo
cd $folder || exit 1
python3.10 -m pip install -r requirements.txt
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: install ${Y}ihack${W} with setuptools ..."
echo
python3.10 -m pip install .
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: cleaning cache after build ${Y}setup.py${W} ..."
[ -d build ] && rm -rf build
[ -d ihack.egg-info ] && rm -rf ihack.egg-info
find . -name "*.jpg" -delete
find . -name "*.png" -delete
find . -name "*.md" -delete
echo
if [ -f /data/data/com.termux/files/usr/bin/ihack ]; then
echo -e "${G}INSTALLATION SUCCESS${W}"
echo
python3.10 -m pip show ihack
echo
echo -e "${W}now you can run instahack with command: ${G}ihack${W}"
echo
else
echo -e "${R}INSTALLATION FAILED${W}"
echo
fi
}
linux() {
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: running installer for linux ..."
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: adding package repository ${Y}ppa:savoury1/python${W} ..."
echo
sudo apt-get install software-properties-common -y
sudo add-apt-repository ppa:deadsnakes/ppa
sudo apt-get update
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: installing ${Y}git${W}, ${Y}python3.10${W} ..."
echo
sudo apt-get install git -y
sudo apt-get install python3.10 python3.10-venv python3.10-distutils -y
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: cloning github repository ..."
echo
if [ -d $folder ]; then
mv $folder "${folder}-backup"
fi
git clone --depth 1 https://github.com/termuxhackers-id/instahack
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: install ${Y}pip3.10${W} ..."
echo
curl -sS https://bootstrap.pypa.io/get-pip.py | sudo python3.10
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: install ${Y}requirements.txt${W} with pip3.10 ..."
echo
cd $folder || exit 1
python3.10 -m pip install -r requirements.txt
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: install ${Y}ihack${W} with setuptools ..."
echo
python3.10 -m pip install .
echo
echo -e "${W}[ ${B}INFO${W} ] ${G}INSTAHACK${W}: cleaning cache after build ${Y}setup.py${W} ..."
[ -d build ] && rm -rf build
[ -d ihack.egg-info ] && rm -rf ihack.egg-info
find . -name "*.jpg" -delete
find . -name "*.png" -delete
find . -name "*.md" -delete
echo
if command -v ihack &> /dev/null; then
echo -e "${G}INSTALLATION SUCCESS${W}"
echo
python3.10 -m pip show ihack
echo
echo -e "${W}now you can run instahack with command: ${G}ihack${W}"
echo
else
echo -e "${R}INSTALLATION FAILED${W}"
echo
fi
}
if command -v termux-change-repo &> /dev/null; then
termux
else
linux
fi