一些提升生活质量的 Gnome 配置。
禁用输错密码账号锁定
配置:/etc/security/faillock.conf,设置 deny = 0。
Workspace Indicator 显示工作区名
DConf 路径:/org/gnome/desktop/wm/preferences/workspace-names。
插件路径:$HOME/.local/share/gnome-shell/extensions/workspace-indicator@gnome-shell-extensions.gcampax.github.com,修改 extension.js:
_labelText(workspaceIndex) {
if (workspaceIndex === undefined) {
workspaceIndex = this._currentWorkspace;
- return (workspaceIndex + 1).toString();
+ return Meta.prefs_get_workspace_name(workspaceIndex) + " (" + (workspaceIndex + 1).toString() + ")";
}
return Meta.prefs_get_workspace_name(workspaceIndex);
}
在绘制 labelText 时,如果没有传进 index 参数,就只会显示一个数字,我个人觉得挺怪的。
修改完成后,Alt+F2 输入 r 重启即可。
3.38.1 更新
新路径:/usr/share/gnome-shell/extensions/workspace-indicator@gnome-shell-extensions.gcampax.github.com。
禁用自动 Hibernate
Gnome 的休眠 bug 实在太多了。
DConf 路径:/org/gnome/settings-daemon/plugins/power/sleep-inactive-battery-type。
Context Menu 配置
安装 filemanager-actions。
在设置中,取消勾选
Create a root 'FileManager-Actions' menu添加
Open in Code- 勾选
Display item in location context menu - Command - Path 设置为
code,参数为%B
- 勾选