Migrate to chezmoi

Move config files from config to chezmoi
Add script to auto install packages with DNF and Cargo
This commit is contained in:
Alexander Navarro 2024-03-01 20:25:09 -03:00
parent 110e0882c6
commit 224c7ed45c
1654 changed files with 470035 additions and 51 deletions

View file

@ -0,0 +1,19 @@
local utils = require 'mp.utils'
local pid = utils.getpid()
local function center_floating_mpv()
mpv_window_id = io.popen("xdotool search --pid " .. pid):read()
-- mpv can have a slight delay in launching a window, or be called without one at all
if mpv_window_id == nil then return end
floating = io.popen("xprop -id " .. mpv_window_id):read("*a")
if string.match(floating, "FLOATING") then
os.execute("i3-msg -q '[id=" .. mpv_window_id .. "]' move position center")
end
end
mp.register_event("playback-restart", center_floating_mpv)
-- mpv should still be centered when fullscreen is toggled
mp.observe_property("fullscreen", "bool", center_floating_mpv)