Ubuntu: Open multiple firefox tabs from command line



Question:

I'm trying to open firefox with two tabs from the command line, with two separate web addresses. So far I'm having no luck.

firefox -new-tab https://www.evernote.com/Home.action -new-tab http://www.gmail.com  

Could someone point me in the right direction?


Solution:1

Oops. I just found the answer. You need to add a -url after each `-new-tab'.

firefox -new-tab -url https://www.evernote.com/Home.action -new-tab -url http://www.gmail.com  

Now it works. Hope this can help somebody.


Solution:2

Create a file containing list of URLs called url.txt:

http://www.url1.xxx  http://www.url2.xxx  http://www.url3.xxx  

Firefox uses the new-tab command, so you could pass the URLs in the file to the browser like so:

xargs -a url.txt firefox -new-tab "$line"  


Solution:3

Update: Now you no need to add -url simple write firefox then web url name separated by space.

firefox mail.google.com askubuntu.com stackoverflow.com  

Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »