2024-07-27 02:10:32 +00:00
|
|
|
#!/bin/bash
|
2022-01-12 08:30:26 +00:00
|
|
|
|
2022-01-12 08:59:40 +00:00
|
|
|
curl "https://api.github.com/repos/xvzc/SpoofDPI/releases/latest" |
|
2023-09-08 08:35:41 +00:00
|
|
|
grep '"tag_name":' |
|
2022-01-12 08:30:26 +00:00
|
|
|
sed -E 's/.*"([^"]+)".*/\1/' |
|
2024-08-27 03:17:35 +00:00
|
|
|
xargs -I {} curl -OL "https://github.com/xvzc/SpoofDPI/releases/download/"\{\}"/spoofdpi-${1}.tar.gz"
|
2022-01-12 08:30:26 +00:00
|
|
|
|
2024-08-27 03:17:35 +00:00
|
|
|
mkdir -p ~/.spoofdpi/bin
|
2022-01-12 11:59:26 +00:00
|
|
|
|
2024-08-27 03:17:35 +00:00
|
|
|
tar -xzvf ./spoofdpi-${1}.tar.gz && \
|
|
|
|
rm -rf ./spoofdpi-${1}.tar.gz && \
|
|
|
|
mv ./spoofdpi ~/.spoofdpi/bin
|
2022-01-12 13:34:26 +00:00
|
|
|
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
echo "Error. exiting now"
|
|
|
|
exit
|
|
|
|
fi
|
|
|
|
|
2024-08-27 03:17:35 +00:00
|
|
|
export PATH=$PATH:~/.spoofdpi/bin
|
2022-01-12 13:34:26 +00:00
|
|
|
|
|
|
|
echo ""
|
|
|
|
echo "Successfully installed SpoofDPI."
|
|
|
|
echo "Please add the line below to your rcfile(.bashrc or .zshrc etc..)"
|
|
|
|
echo ""
|
2024-08-27 03:17:35 +00:00
|
|
|
echo ">> export PATH=\$PATH:~/.spoofdpi/bin"
|