1 -- Awesome libraries {{{1
2 gears = require("gears")
3 awful = require("awful")
4 awful.rules = require("awful.rules")
5 require("awful.autofocus")
6 beautiful = require("beautiful")
7 naughty = require("naughty")
8 menubar = require("menubar")
10 require("awful.remote")
12 -- Error handling {{{1
13 -- Check if awesome encountered an error during startup and fell back to
14 -- another config (This code will only ever execute for the fallback config)
15 if awesome.startup_errors then
16 naughty.notify({ preset = naughty.config.presets.critical,
17 title = "Oops, there were errors during startup!",
18 text = awesome.startup_errors })
21 -- Handle runtime errors after startup
23 local in_error = false
24 awesome.connect_signal("debug::error", function (err)
25 -- Make sure we don't go into an endless error loop
26 if in_error then return end
29 naughty.notify({ preset = naughty.config.presets.critical,
30 title = "Oops, an error happened!",
31 text = tostring(err) })
36 -- Variable definitions {{{1
37 -- Themes define colours, icons, font and wallpapers.
38 beautiful.init(awful.util.getdir("config").."/themes/mlp/theme.lua")
40 -- This is used later as the default terminal and editor to run.
42 editor = os.getenv("EDITOR") or "vim"
43 editor_cmd = terminal .. " -e " .. editor