Bash 打开 Firefox 窗口,然后在选项卡中打开每个后续窗口
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/2153030/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Bash open Firefox Window, then each subsequent window in tabs
提问by Chasester
I know as long as Firefox has the "New pages should be opened in - a new tab" selected, the following code will open specified urls in new tabs to the firefox window last selected.
我知道只要 Firefox 选择了“新页面应该在 - 新标签页中打开”,下面的代码就会在新标签页中打开指定的 url 到最后选择的 Firefox 窗口。
firefox '<url here>'
Works great. However with many tabs to open the user needs to leave computer as until all open as desired.
效果很好。但是,要打开许多选项卡,用户需要离开计算机,直到按需要全部打开为止。
Is it possible to (in bash):
是否可以(在 bash 中):
A) Launch a new Firefox window, open all subsequent pages in tabs in that window and B) Let the user interact with other open firefox windows while the remaining tabs continue to load in the newly launched firefox window?
A) 启动一个新的 Firefox 窗口,在该窗口中的选项卡中打开所有后续页面,以及 B) 让用户与其他打开的 Firefox 窗口交互,而其余选项卡继续在新启动的 Firefox 窗口中加载?
Thank you!
谢谢!
回答by David J. Liszewski
I think the following addresses part (A) of your requirements:
我认为以下内容解决了您要求的 (A) 部分:
firefox google.com &
firefox -new-tab yahoo.com &
firefox -new-tab bing.com &
Regarding (B), if it is acceptable to ingore the user's existing profile settings, perhaps load something else with the -Poption:
关于(B),如果可以接受用户现有的配置文件设置,也许可以使用该-P选项加载其他内容:
firefox -no-remote -P “<path-to-other-profile>” google.com &
回答by mlathe
this works fine for me:
这对我来说很好用:
firefox http://google.com/ http://yahoo.com/

