forked from tosasitill/HyperOS_Action_builder
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.sh
More file actions
executable file
·29 lines (25 loc) · 853 Bytes
/
setup.sh
File metadata and controls
executable file
·29 lines (25 loc) · 853 Bytes
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
#!/bin/bash
# port requirements
if [ "$(id -u)" != "0" ] && [ "$(uname -m)" == "x86_64" ];then
echo "请以 root 用户运行"
exit
fi
if [ "$(uname -m)" == "x86_64" ] && [ "$(uname)" == "Linux" ];then
echo "Device arch: Linux x86_64"
apt update -y
apt upgrade -y
apt install -y aria2 python3 busybox zip unzip p7zip-full openjdk-8-jre zipalign
if [ $? -ne 0 ];then
echo "安装可能出错,请手动执行:apt install -y python3 busybox zip unzip p7zip-full"
fi
fi
if [ "$(uname -m)" == "aarch64" ];then
echo "Device arch: aarch64"
apt update -y
apt upgrade -y
apt install -y python busybox zip unzip p7zip openjdk-17 zipalign
fi
if [ "$(uname -m)" == "darwin" ] && [ "$(uname -m)" == "x86_64" ];then
echo "Devcie arch: MacOS X86_X64"
brew install aria2 openjdk zstd coreutils
fi