就是 Chrome 么,我想带参数启动。
网上也有那种调整 /Applications 内 Google Chrome
命令的,但这种 版本升级
后是不是又得重新弄?
所以我就每次在iTerm2
中启动 Chrome,因为 iTerm2 我是一直开着的。
但这样 Chrome 就是 iTerm2 的子进程了。在一些统计方面就统计不到 Chrome 了。比如耗电就显示 iTerm2 很耗电,实际是 Chrome 耗电
比如exec
可以把 shell 替换当前 shell,那有木有启动程序但调整 pid 的?
# 我是这样写的
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --参数 2>/dev/null &
![]() |
1
ysc3839 2019-09-14 17:48:26 +08:00 via Android
|
![]() |
2
gIrl1990 OP @ysc3839 哇,谢谢。open --args
All remaining arguments are passed to the opened application in the argv parameter to main(). These arguments are not opened or interpreted by the open tool. `open /Applications/Google\ Chrome.app --args chrome 参数` |