Move terminal setting to our config file
This commit is contained in:
parent
cabc1bf081
commit
d65438528c
@ -5,6 +5,8 @@ local awful = require("awful")
|
||||
|
||||
local config = {}
|
||||
|
||||
-- Terminal
|
||||
config.terminal = "terminator"
|
||||
|
||||
-- Theme
|
||||
-- Change to gears.filesystem.get_themes_dir() .. "default/theme.lua" to use default awesome theme
|
||||
|
11
rc.lua
11
rc.lua
@ -57,9 +57,8 @@ end
|
||||
beautiful.init(config.theme)
|
||||
|
||||
-- This is used later as the default terminal and editor to run.
|
||||
terminal = "terminator"
|
||||
editor = os.getenv("EDITOR") or "nano"
|
||||
editor_cmd = terminal .. " -e " .. editor
|
||||
editor_cmd = config.terminal .. " -e " .. editor
|
||||
|
||||
-- Default modkey.
|
||||
-- Usually, Mod4 is the key with a logo between Control and Alt.
|
||||
@ -93,14 +92,14 @@ awful.layout.layouts = {
|
||||
-- Create a launcher widget and a main menu
|
||||
myawesomemenu = {
|
||||
{ "hotkeys", function() hotkeys_popup.show_help(nil, awful.screen.focused()) end },
|
||||
{ "manual", terminal .. " -e man awesome" },
|
||||
{ "manual", config.terminal .. " -e man awesome" },
|
||||
{ "edit config", editor_cmd .. " " .. awesome.conffile },
|
||||
{ "restart", awesome.restart },
|
||||
{ "quit", function() awesome.quit() end },
|
||||
}
|
||||
|
||||
mymainmenu = awful.menu({ items = { { "awesome", myawesomemenu, beautiful.awesome_icon },
|
||||
{ "open terminal", terminal }
|
||||
{ "open terminal", config.terminal }
|
||||
}
|
||||
})
|
||||
|
||||
@ -108,7 +107,7 @@ mylauncher = awful.widget.launcher({ image = beautiful.awesome_icon,
|
||||
menu = mymainmenu })
|
||||
|
||||
-- Menubar configuration
|
||||
menubar.utils.terminal = terminal -- Set the terminal for applications that require it
|
||||
menubar.utils.terminal = config.terminal -- Set the terminal for applications that require it
|
||||
-- }}}
|
||||
|
||||
-- Keyboard map indicator and switcher
|
||||
@ -297,7 +296,7 @@ globalkeys = gears.table.join(
|
||||
{description = "go back", group = "client"}),
|
||||
|
||||
-- Standard program
|
||||
awful.key({ modkey, }, "Return", function () awful.spawn(terminal) end,
|
||||
awful.key({ modkey, }, "Return", function () awful.spawn(config.terminal) end,
|
||||
{description = "open a terminal", group = "launcher"}),
|
||||
awful.key({ modkey, "Control" }, "r", awesome.restart,
|
||||
{description = "reload awesome", group = "awesome"}),
|
||||
|
Loading…
Reference in New Issue
Block a user