up
This commit is contained in:
24
firetunn.sh
24
firetunn.sh
@@ -18,7 +18,7 @@ then
|
||||
fi
|
||||
|
||||
PORT=$1
|
||||
PROFILE_DIR="$HOME/.mozilla/firefox/ffproxy/socks5-$PORT"
|
||||
PROFILE_DIR="$HOME/.mozilla/firefox/socks5-$PORT"
|
||||
|
||||
# Crea un nuovo profilo Firefox se non esiste
|
||||
if [ ! -d "$PROFILE_DIR" ]; then
|
||||
@@ -34,8 +34,28 @@ if [ ! -d "$PROFILE_DIR" ]; then
|
||||
fi
|
||||
|
||||
|
||||
echo -e '\nfirefox -no-remote -P "socks5-'$PORT'"\n'
|
||||
# PORCODIO
|
||||
VERS=$(curl -s "https://api.github.com/repos/gorhill/uBlock/releases/latest" | jq -r .tag_name | sed 's/..$//')
|
||||
mkdir -p $PROFILE_DIR/extensions
|
||||
cd /$PROFILE_DIR/extensions
|
||||
# Scarica ublock Origin
|
||||
wget -q https://github.com/gorhill/uBlock/releases/download/$VERS.1b7/uBlock0_$VERS.1b7.firefox.signed.xpi
|
||||
# Compila il manifest.json
|
||||
cat <<EOL > $PROFILE_DIR/extensions/manifest.json
|
||||
{
|
||||
"manifest_version": 2,
|
||||
"name": "uBlock Origin",
|
||||
"version": "$VERS.1b7",
|
||||
"applications": {
|
||||
"gecko": {
|
||||
"id": "uBlock0@raymondhill.net"
|
||||
}
|
||||
}
|
||||
}
|
||||
EOL
|
||||
|
||||
|
||||
echo -e '\nfirefox -no-remote -P "socks5-'$PORT'"\n'
|
||||
|
||||
# Avvia Firefox con quel profilo
|
||||
firefox -no-remote -P "socks5-$PORT" > /dev/null 2>&1 &
|
||||
|
||||
Reference in New Issue
Block a user