-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathrequirements.sh
44 lines (36 loc) · 1.01 KB
/
requirements.sh
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
#!/bin/bash
####################################
# EvilAPKMastermind Requirements Installer
# Author: 1cYinfinity
####################################
# Colors for terminal output
RED='\033[0;31m'
GREEN='\033[0;32m'
NC='\033[0m' # No Color
# Function to display an error message and exit
display_error() {
echo -e "${RED}Error: $1${NC}" >&2
exit 1
}
# Function to display a success message
display_success() {
echo -e "${GREEN}$1${NC}"
}
# Function to check if a command is available
check_command() {
command -v "$1" >/dev/null 2>&1
}
# Function to install a package if it is not available
install_package() {
sudo apt-get install -y "$1" || display_error "Failed to install $1"
}
# Check and install required dependencies
dependencies=("apktool" "smali" "zipalign" "openjdk-11-jdk")
for dep in "${dependencies[@]}"; do
if ! check_command "$dep"; then
echo "Installing $dep..."
install_package "$dep"
fi
done
# Display success message
display_success "EvilAPKMastermind requirements installed successfully!"