making init work with a slightly updated fennel

This commit is contained in:
Chris Cochrun 2022-04-01 13:19:29 -05:00
parent eebfc39eb9
commit c4cd1393a5
7 changed files with 46 additions and 27 deletions

View file

@ -363,10 +363,10 @@ package.preload["fennel.repl"] = package.preload["fennel.repl"] or function(...)
_571_ = _572_
end
end
if ((_G.type(_571_) == "table") and (nil ~= (_571_).source) and ((_571_).what == "Lua") and (nil ~= (_571_).linedefined) and (nil ~= (_571_).short_src)) then
local source = (_571_).source
local line = (_571_).linedefined
if ((_G.type(_571_) == "table") and (nil ~= (_571_).short_src) and (nil ~= (_571_).linedefined) and ((_571_).what == "Lua") and (nil ~= (_571_).source)) then
local src = (_571_).short_src
local line = (_571_).linedefined
local source = (_571_).source
local fnlsrc
do
local t_576_ = compiler.sourcemap

View file

@ -18,29 +18,30 @@
(local ruled (require "ruled"))
;; my splits
(local clientrules (require "rules"))
(local keybindings (require "keybindings"))
(local notifications (require "notifications"))
(local clientrules (require :rules))
(local keybindings (require :keybindings))
(local notifications (require :notifications))
;; Error handling
;; Check if awesome encountered an error during startup and fall back to
;; another config (This code will only ever execute for the fallback config)
(when awesome.startup_errors
(naughty.notify {:preset naughty.config.presets.critical
:title "Oops, there were errors during startup!"
:text awesome.startup_errors}))
:title "Oops, there were errors during startup!"
:text awesome.startup_errors}))
;; Handle runtime errors after startup
(do
(var in_error false)
(awesome.connect_signal "debug::error" (fn [err]
;; Make sure we don't go into an endless error loop
(when (not in_error)
(set in_error true)
(naughty.notify {:preset naughty.config.presets.critical
:title "Oops, an error happened!"
:text (tostring err)})
(set in_error false)))))
(var in_error false)
(awesome.connect_signal "debug::error" (fn [err]
;; Make sure we don't go into an endless error loop
(when (not in_error)
(set in_error true)
(naughty.notify {:preset naughty.config.presets.critical
:title "Oops, an error happened!"
:text (tostring err)})
(set in_error false)))))

View file

@ -1,7 +1,20 @@
pcall(require, "luarocks.loader")
fennel = require("fennel")
local gears = require("gears")
fennel.path = fennel.path .. ";.config/awesome/?.fnl"
table.insert(package.loaders or package.searchers, fennel.searcher)
local naughty = require("naughty")
cfgDir = os.getenv("HOME") .. "/.config/awesome/"
-- package.path = cfgDir .. "?.lua"
fennel.path = fennel.path .. ";" .. cfgDir .. "?.fnl;"
searcher = fennel.make_searcher({
correlate = true,
useMetadata = true,
-- disable strict checking.
-- TODO: assemble a full list of globals so we can enable this
-- allowedGlobals = false
})
table.insert(package.loaders or package.searchers, fennel.searcher)
debug.traceback = fennel.traceback
require("init") -- load ~/.config/awesome/init.fnl

View file

@ -1,7 +1,7 @@
(local awful (require "awful"))
(local naughty (require "naughty"))
(local gears (require "gears"))
(local beautiful (require "beautiful"))
(local keybindings (require "keybindings"))
(local xresources (require "beautiful.xresources"))
(local dpi xresources.apply_dpi)
@ -38,7 +38,9 @@
:floating true
:raise true
:height (dpi 1000)
:screen (screen.count)
:screen (if (= (screen.count) 3)
2
(screen.count))
:sticky true
:placement awful.placement.centered
}
@ -168,7 +170,9 @@
]
}
:properties {
:screen (screen.count)
:screen (if (= (screen.count) 3)
2
(screen.count))
:focus awful.client.focus.filter
:raise true
}

View file

@ -3,7 +3,7 @@
SETUVAR --export ANDROID_SDK_ROOT:/opt/android\x2dsdk
SETUVAR --export CHROME_EXECUTABLE:/usr/bin/qutebrowser
SETUVAR --export JAVA_HOME:/usr/lib/jvm/default
SETUVAR __fish_initialized:3100
SETUVAR __fish_initialized:3400
SETUVAR fish_color_autosuggestion:555\x1ebrblack
SETUVAR fish_color_cancel:\x2dr
SETUVAR fish_color_command:005fd7
@ -33,4 +33,5 @@ SETUVAR fish_pager_color_completion:\x1d
SETUVAR fish_pager_color_description:B3A06D\x1eyellow
SETUVAR fish_pager_color_prefix:white\x1e\x2d\x2dbold\x1e\x2d\x2dunderline
SETUVAR fish_pager_color_progress:brwhite\x1e\x2d\x2dbackground\x3dcyan
SETUVAR fish_pager_color_selected_background:\x2dr
SETUVAR fish_user_paths:/home/chris/\x2elocal/bin\x1e/home/chris/scripts\x1e/home/chris/\x2edoom\x2demacs/bin\x1e/home/chris/\x2eemacs\x2ed/bin\x1e/home/chris/\x2ecargo/bin\x1e/opt/android\x2dsdk/cmdline\x2dtools/latest/bin

View file

@ -2,8 +2,8 @@
osc=no
vo=gpu
af=scaletempo2
autofit=90%
geometry=90%:90%
autofit=70%
geometry=80%:80%
# input-ipc-server="/tmp/mpvsocket"
hwdec=auto
rtsp-transport=udp

View file

@ -1,6 +1,6 @@
[FileDialog]
history=@Invalid()
lastVisited=file:///home/chris/
history=file:///home/chris/Videos/paul
lastVisited=file:///home/chris/Videos/paul
qtVersion=5.15.3
shortcuts=file:, file:///home/chris, file:///home/chris/storage/tfc
sidebarWidth=116