Gtk Warning when starting TOR on PureOS

Hi, I am trying to run TOR and I got this message. “Ligação recusada” is “refused connection”.

root@miguel-x411unv:/home/miguel/Programas/tor-browser_en-US# ./start-tor-browser.desktop --register-app
Launching ‘./Browser/start-tor-browser --detach --register-app’…
./Browser/start-tor-browser: linha 28: [: : expressão inteira esperada
Unable to init server: impossível ligar: Ligação recusada

(zenity:921): Gtk-WARNING **: 11:49:36.586: cannot open display:

Any tips?

This was simply solved, TOR shouldn’t have been installed under root privileges. I just reinstalled it and followed the command line steps documented on the Tor Project website. Then ran the command with this argument:

./start-tor-browser.desktop --register-app

in order to have TOR Browser shown up with the other installed apps as explained here:

TOR is working and it can be lanched as other applications.