Answers:
导航到桌面启动器/菜单项,打开google chrome的启动器属性对话框。
它看起来应该像这样:
/usr/bin/google-chrome %U
要使您想要的标志成为永久标志,请将其修改为:
/usr/bin/google-chrome --allow-file-access-from-files
修改后,您可能还需要删除并重新固定图标启动器。修改后,Chrome应该在启用了指定标志的情况下启动。
或者,您可以简单地使用上面的代码创建一个新的启动器,然后使用它来启动chrome。
要检查是否已加载您修改的标志:
$ cat ~/.config/google-chrome/Local\ State
并向上滚动到标题为
"session_restore"
您的标志应列在块中,然后
--flag-switches-begin --flag-switches-end
。
打开Chrome浏览器并导航到URL
chrome://version/
还应该在
Command Line
块
这是google-chrome / chrome标志的列表:
诸如--allow-file-access-from-files
标志/开关之类的不同模式并不适合一般用户使用。因此,您不能使用常规版本永久更改它。这些开关/参数的目的是提供选择。不支持也不推荐使用这些标志,并且必须将它们用作临时标志。
由于您不想使用.desktop
文件或更改任何快捷方式。您唯一可以做的就是查看开源代码chorimium
。
自定义代码并进行构建。然后只有它会以您想要的模式打开。
Google-chrome和Chromium的功能应相同,区别仅在于多媒体(特别是Flash)和一些文件/文件夹位置(铬而不是google-chrome),请参见http://code.google.com/p/chromium / wiki / ChromiumBrowserVsGoogleChrome
您应该 特别查看https://wiki.archlinux.org/index.php/Chromium_Tips_and_Tweaks:
Making it all persistent
You can export your flags from ~/.profile:
export CHROMIUM_USER_FLAGS="--disk-cache-dir=/tmp --disk-cache-size=50000000"
Or add them to /etc/chromium/default:
# Default settings for chromium. This file is sourced by /usr/bin/chromium
#
# Options to pass to chromium
CHROMIUM_FLAGS="--scroll-pixels=200"
Chromium will prefer the user defined flags in CHROMIUM_USER_FLAGS to those defined in
/etc/chromium/default.
CHROME_USER_FLAGS=
来/etc/skel/.bashrc
当笔记本电脑内置
How can I make that option always be turned on when ever google chrome is executed beyond running a .desktop every time
从问题中删除部分内容,因为这会造成混乱。