File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 22# Author https://github.com/grigruss
33
44# Check translate-shell script
5- if [[ ! $( trans -V) ]]
5+ if ! trans -V > /dev/null
66then
77 echo -e " \\ n\\ e[33mWARNING!\\ n========\\ e[0m"
88 echo -e " To run the script, you need a 'trans' script from this repository:"
1111fi
1212
1313# Check curl
14- if [[ ! $( curl -V) ]]
14+ if ! curl -V > /dev/null
1515then
1616 echo -e " \\ n\\ e[33mWARNING!\\ n========\\ e[0m"
1717 echo -e " To run the script, you need install 'curl'"
3131 shift
3232done
3333
34- src=$( curl " cht.sh/${U} ?T" )
34+ src=$( curl " cht.sh/${U} ?T" 2> /dev/null )
3535IFS=$' \n '
3636S=' '
3737for answ in $src
@@ -58,11 +58,11 @@ for answ in $src
5858do
5959 if [[ " ${answ: 0: 1} " == " #" ]]
6060 then
61- VR=" ${R[" $count" ]//#/# \[ $lang \] } "
61+ VR=" ${R[$count]//#/# \[ $lang \] } "
6262 VE=" ${answ//#/# \[ en\] } "
6363 if [[ " $T " == 0 ]]
6464 then
65- echo -e " \e[32;1m$VR \e[0m\n\e[32m $VE \e[0m"
65+ echo -e " \e[32;1m$VR \e[0m\n\e[30;1m $VE \e[0m"
6666 else
6767 echo -e " $VR \n$VE "
6868 fi
You can’t perform that action at this time.
0 commit comments