-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathkobopatch.sh
executable file
·42 lines (40 loc) · 1.13 KB
/
kobopatch.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
#!/bin/bash
export TAILSCALE_VERSION=1.78.1
cd "$(dirname "$0")"
if [ ! -f src/tailscale-${TAILSCALE_VERSION}-arm.tgz ]; then
echo "Downloading tailscale_${TAILSCALE_VERSION}_arm.tgz from pkgs.tailscale.com ..."
curl --progress-bar -o src/tailscale-${TAILSCALE_VERSION}-arm.tgz https://pkgs.tailscale.com/stable/tailscale_${TAILSCALE_VERSION}_arm.tgz
rm -rf src/tailscale
tar -xvf src/tailscale-${TAILSCALE_VERSION}-arm.tgz -C src
mv src/tailscale_${TAILSCALE_VERSION}_arm src/tailscale
fi
mkdir -p out && rm -f "out/KoboRoot.tgz"
case `uname -s` in
Darwin)
case `uname -m` in
x86_64)
./bin/kobopatch-darwin-64bit
;;
arm*)
./bin/kobopatch-darwin-arm
;;
aarch64)
./bin/kobopatch-darwin-arm
;;
*)
echo "Unsupported architecture"
esac
;;
Linux)
case `uname -m` in
x86_64)
./bin/kobopatch-linux-64bit
;;
*)
echo "Unsupported architecture"
esac
;;
*)
echo "Unsupported system"
;;
esac