You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
34 lines
856 B
34 lines
856 B
#!/bin/bash
|
|
source fnc_gonzy.sh
|
|
|
|
function fnc_principal(){
|
|
fnc_gonzy_intro "URL_Descifrar" "Descifra URL acortada.\np.e. https://tinyurl.com/msxc5ydt"
|
|
|
|
UrlAcortada="$1"
|
|
if [ "$UrlAcortada" == "" ]; then
|
|
echo -e "${Red}"
|
|
center_text $UrlAcortada
|
|
echo -e "${Color_Off}"
|
|
else
|
|
Url=$(curl -s --head "$UrlAcortada" 2>/dev/null | grep -i 'location' | awk '{print $2}')
|
|
UrlFinal=$(curl -s --head "$Url" 2>/dev/null | grep -i 'location' | awk '{print $2}')
|
|
if [ "$UrlFinal" == "" ]; then
|
|
pagi="$Url"
|
|
else
|
|
pagi="$UrlFinal"
|
|
fi
|
|
fi
|
|
|
|
echo -e "\n"
|
|
termux-clipboard-set $pagi
|
|
fnc_msg_color 2 "Descifrando URL."
|
|
sleep 1
|
|
echo -e "\n"
|
|
fnc_msg_color 1 "URL descifrada."
|
|
fnc_msg_color 2 $pagi
|
|
fnc_msg_color 1 "URL en portapapeles!"
|
|
echo ""
|
|
}
|
|
|
|
read -p "URL corta: " url_corta;
|
|
fnc_principal $url_corta |