【发布时间】:2013-08-10 22:15:06
【问题描述】:
可以用firefox -P <profile-name> -no-remote启动不同的firefox配置文件
但是,当我想在 linux 中同时使用批处理文件启动多个配置文件时,只有第一个配置文件启动,而后续配置文件在前一个退出之前不会启动。
目前我无法使用此批处理脚本:
#! /bin/bash
firefox -P "profile 1" -no-remote
firefox -P "profile 2" -no-remote
firefox -P "profile 3" -no-remote
基本上,profile 1 启动良好,但 profile 2 直到我先退出 Firefox 后才启动;下一个命令在上一个退出之前不会执行。
在 Windows 中,我已经成功地使用这个 bat 文件同时启动了多个 firefox:
start "" "C:\Program Files (x86)\Mozilla Firefox\firefox.exe" -P "profile 1"
start "" "C:\Program Files (x86)\Mozilla Firefox\firefox.exe" -P "profile 2"
start "" "C:\Program Files (x86)\Mozilla Firefox\firefox.exe" -P "profile 3"
start 之后的引号有助于实现这一点,start 之后没有引号,配置文件不会同时启动,但在 linux 中我不知道如何实现这一点?
【问题讨论】:
-
您需要通过在命令末尾添加
&在后台运行它们 -
哇,我真是个菜鸟!一个符号可以杀死你或让你活着。非常感谢!所有配置文件同时启动
-
@KeepCalmAndCarryOn:请作为答案发布,以便 OP 可以接受并将其标记为已解决。
-
将我的评论移至答案
标签: linux bash firefox command-line