Compare commits

..

22 Commits

Author SHA1 Message Date
82b0f111c2 added nvim 2025-09-30 19:35:36 +02:00
70c935e1a9 pre fix 2025-08-17 18:31:11 +02:00
c21dcb78a2 removed useless definition 2025-08-17 16:15:22 +02:00
5a024099e4 added gitiognore 2025-08-17 15:57:18 +02:00
a598584cc3 finalizing touches before test 2025-08-17 15:48:47 +02:00
cb60c396b1 removed pycache 2025-08-17 14:46:56 +02:00
e301413fc2 added theme and widgets to screens 2025-08-17 14:46:12 +02:00
0e103467a1 added screens 2025-08-17 12:52:21 +02:00
e79c21974c added unchanged autostart script 2025-08-17 12:02:16 +02:00
c266d2c358 added layouts 2025-08-17 12:01:29 +02:00
a4a63a314f added default layout defaults 2025-08-17 11:57:03 +02:00
c39ed6794f added default widget styling 2025-08-17 11:56:14 +02:00
15634f51ff added group configuration 2025-08-17 11:53:34 +02:00
aa46a5b7e2 added hooks 2025-08-17 11:53:12 +02:00
72d1ab4e27 added mouse config 2025-08-17 10:53:23 +02:00
ff415386b6 apps 2025-08-16 23:16:47 +02:00
0ba548f7e5 added last keybinds and cleaned up 2025-08-16 23:16:14 +02:00
97f4e83971 added more keybinds 2025-08-16 20:09:01 +02:00
0a5eb3c5a1 cleanup yazi config file 2025-08-16 16:41:34 +02:00
370a47e816 added more keybinds 2025-08-16 16:39:36 +02:00
a02e6b5b88 made default apps to an tuple 2025-08-16 13:52:14 +02:00
212f9febc0 update config.py 2025-08-16 13:49:40 +02:00
36 changed files with 2086 additions and 295 deletions

3
.gitignore vendored Normal file
View File

@@ -0,0 +1,3 @@
qtile/modules/__pycache__/
qtile/plugins/__pycache__/
qtile/popups/__pycache__/

8
nvim/.gitignore vendored Normal file
View File

@@ -0,0 +1,8 @@
tt.*
.tests
doc/tags
debug
.repro
foo.*
*.log
data

15
nvim/.neoconf.json Normal file
View File

@@ -0,0 +1,15 @@
{
"neodev": {
"library": {
"enabled": true,
"plugins": true
}
},
"neoconf": {
"plugins": {
"lua_ls": {
"enabled": true
}
}
}
}

201
nvim/LICENSE Normal file
View File

@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

4
nvim/README.md Normal file
View File

@@ -0,0 +1,4 @@
# 💤 LazyVim
A starter template for [LazyVim](https://github.com/LazyVim/LazyVim).
Refer to the [documentation](https://lazyvim.github.io/installation) to get started.

2
nvim/init.lua Normal file
View File

@@ -0,0 +1,2 @@
-- bootstrap lazy.nvim, LazyVim and your plugins
require("config.lazy")

43
nvim/lazy-lock.json Normal file
View File

@@ -0,0 +1,43 @@
{
"LazyVim": { "branch": "main", "commit": "25abbf546d564dc484cf903804661ba12de45507" },
"LuaSnip": { "branch": "master", "commit": "21f74f7ba8c49f95f9d7c8293b147c2901dd2d3a" },
"SchemaStore.nvim": { "branch": "main", "commit": "2ae6d27897c60265d4ad3f33e286528d519098fd" },
"blink.cmp": { "branch": "main", "commit": "bae4bae0eedd1fa55f34b685862e94a222d5c6f8" },
"bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" },
"catppuccin": { "branch": "main", "commit": "30fa4d122d9b22ad8b2e0ab1b533c8c26c4dde86" },
"conform.nvim": { "branch": "master", "commit": "b4aab989db276993ea5dcb78872be494ce546521" },
"dial.nvim": { "branch": "master", "commit": "f0404ec1f83a03f2c3457e60087c6331d1cbb83f" },
"flash.nvim": { "branch": "main", "commit": "3c942666f115e2811e959eabbdd361a025db8b63" },
"friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" },
"fzf-lua": { "branch": "main", "commit": "70cdea35ac8fe5e3a977616b883d780a842cc115" },
"gitsigns.nvim": { "branch": "main", "commit": "6e3c66548035e50db7bd8e360a29aec6620c3641" },
"grug-far.nvim": { "branch": "main", "commit": "c5b629399c0f2e436c00df381e44852a13b7313a" },
"gruvbox.nvim": { "branch": "main", "commit": "5e0a460d8e0f7f669c158dedd5f9ae2bcac31437" },
"lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" },
"lazydev.nvim": { "branch": "main", "commit": "2367a6c0a01eb9edb0464731cc0fb61ed9ab9d2c" },
"lualine.nvim": { "branch": "master", "commit": "b8c23159c0161f4b89196f74ee3a6d02cdc3a955" },
"markdown-preview.nvim": { "branch": "master", "commit": "a923f5fc5ba36a3b17e289dc35dc17f66d0548ee" },
"mason-lspconfig.nvim": { "branch": "main", "commit": "1a31f824b9cd5bc6f342fc29e9a53b60d74af245" },
"mason.nvim": { "branch": "main", "commit": "fc98833b6da5de5a9c5b1446ac541577059555be" },
"mini.ai": { "branch": "main", "commit": "45a26d032d8703f280c69c2ed9fb4e1bfc8f24f9" },
"mini.icons": { "branch": "main", "commit": "f9a177c11daa7829389b7b6eaaec8b8a5c47052d" },
"mini.pairs": { "branch": "main", "commit": "6e1cc569130f25b2c6fa16d8b21b31ddb1420a4a" },
"neo-tree.nvim": { "branch": "main", "commit": "ed057048a281b418d5318dd5153f9486daa517a3" },
"noice.nvim": { "branch": "main", "commit": "0427460c2d7f673ad60eb02b35f5e9926cf67c59" },
"nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" },
"nvim-lint": { "branch": "master", "commit": "f126af5345c7472e9a0cdbe1d1a29209be72c4c4" },
"nvim-lspconfig": { "branch": "master", "commit": "3e89e4973d784e1c966517e528b3a30395403fa7" },
"nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" },
"nvim-treesitter-textobjects": { "branch": "master", "commit": "71385f191ec06ffc60e80e6b0c9a9d5daed4824c" },
"nvim-ts-autotag": { "branch": "main", "commit": "a1d526af391f6aebb25a8795cbc05351ed3620b5" },
"persistence.nvim": { "branch": "main", "commit": "166a79a55bfa7a4db3e26fc031b4d92af71d0b51" },
"plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" },
"render-markdown.nvim": { "branch": "main", "commit": "e76eb2e4262f0f0a1a7bd7a454dd7d44f1299afd" },
"snacks.nvim": { "branch": "main", "commit": "bc0630e43be5699bb94dadc302c0d21615421d93" },
"todo-comments.nvim": { "branch": "main", "commit": "304a8d204ee787d2544d8bc23cd38d2f929e7cc5" },
"tokyonight.nvim": { "branch": "main", "commit": "057ef5d260c1931f1dffd0f052c685dcd14100a3" },
"trouble.nvim": { "branch": "main", "commit": "85bedb7eb7fa331a2ccbecb9202d8abba64d37b3" },
"ts-comments.nvim": { "branch": "main", "commit": "1bd9d0ba1d8b336c3db50692ffd0955fe1bb9f0c" },
"which-key.nvim": { "branch": "main", "commit": "370ec46f710e058c9c1646273e6b225acf47cbed" },
"yanky.nvim": { "branch": "main", "commit": "04775cc6e10ef038c397c407bc17f00a2f52b378" }
}

18
nvim/lazyvim.json Normal file
View File

@@ -0,0 +1,18 @@
{
"extras": [
"lazyvim.plugins.extras.coding.luasnip",
"lazyvim.plugins.extras.coding.yanky",
"lazyvim.plugins.extras.editor.dial",
"lazyvim.plugins.extras.lang.git",
"lazyvim.plugins.extras.lang.markdown",
"lazyvim.plugins.extras.lang.python",
"lazyvim.plugins.extras.lang.toml",
"lazyvim.plugins.extras.lang.yaml",
"lazyvim.plugins.extras.util.dot"
],
"install_version": 7,
"news": {
"NEWS.md": "10960"
},
"version": 8
}

View File

@@ -0,0 +1,8 @@
-- Autocmds are automatically loaded on the VeryLazy event
-- Default autocmds that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/autocmds.lua
--
-- Add any additional autocmds here
-- with `vim.api.nvim_create_autocmd`
--
-- Or remove existing autocmds by their group name (which is prefixed with `lazyvim_` for the defaults)
-- e.g. vim.api.nvim_del_augroup_by_name("lazyvim_wrap_spell")

View File

@@ -0,0 +1,3 @@
-- Keymaps are automatically loaded on the VeryLazy event
-- Default keymaps that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/keymaps.lua
-- Add any additional keymaps here

53
nvim/lua/config/lazy.lua Normal file
View File

@@ -0,0 +1,53 @@
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not (vim.uv or vim.loop).fs_stat(lazypath) then
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
if vim.v.shell_error ~= 0 then
vim.api.nvim_echo({
{ "Failed to clone lazy.nvim:\n", "ErrorMsg" },
{ out, "WarningMsg" },
{ "\nPress any key to exit..." },
}, true, {})
vim.fn.getchar()
os.exit(1)
end
end
vim.opt.rtp:prepend(lazypath)
require("lazy").setup({
spec = {
-- add LazyVim and import its plugins
{ "LazyVim/LazyVim", import = "lazyvim.plugins" },
-- import/override with your plugins
{ import = "plugins" },
},
defaults = {
-- By default, only LazyVim plugins will be lazy-loaded. Your custom plugins will load during startup.
-- If you know what you're doing, you can set this to `true` to have all your custom plugins lazy-loaded by default.
lazy = false,
-- It's recommended to leave version=false for now, since a lot the plugin that support versioning,
-- have outdated releases, which may break your Neovim install.
version = false, -- always use the latest git commit
-- version = "*", -- try installing the latest stable version for plugins that support semver
},
install = { colorscheme = { "tokyonight", "habamax" } },
checker = {
enabled = true, -- check for plugin updates periodically
notify = false, -- notify on update
}, -- automatically check for plugin updates
performance = {
rtp = {
-- disable some rtp plugins
disabled_plugins = {
"gzip",
-- "matchit",
-- "matchparen",
-- "netrwPlugin",
"tarPlugin",
"tohtml",
-- "tutor",
"zipPlugin",
},
},
},
})

View File

@@ -0,0 +1,5 @@
-- Options are automatically loaded before lazy.nvim startup
-- Default options that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/options.lua
-- Add any additional options here
vim.opt.colorcolumn = "72,79"

View File

@@ -0,0 +1,12 @@
return {
-- add gruvbox
{ "ellisonleao/gruvbox.nvim" },
-- Configure LazyVim to load gruvbox
{
"LazyVim/LazyVim",
opts = {
colorscheme = "gruvbox",
},
},
}

View File

@@ -0,0 +1,202 @@
-- since this is just an example spec, don't actually load anything here and return an empty spec
-- stylua: ignore
if true then return {} end
-- every spec file under the "plugins" directory will be loaded automatically by lazy.nvim
--
-- In your plugin files, you can:
-- * add extra plugins
-- * disable/enabled LazyVim plugins
-- * override the configuration of LazyVim plugins
return {
-- add gruvbox
{ "ellisonleao/gruvbox.nvim" },
-- Configure LazyVim to load gruvbox
{
"LazyVim/LazyVim",
opts = {
colorscheme = "gruvbox",
},
},
-- change trouble config
{
"folke/trouble.nvim",
-- opts will be merged with the parent spec
opts = { use_diagnostic_signs = true },
},
-- disable trouble
{ "folke/trouble.nvim", enabled = false },
-- override nvim-cmp and add cmp-emoji
{
"hrsh7th/nvim-cmp",
dependencies = { "hrsh7th/cmp-emoji" },
---@param opts cmp.ConfigSchema
opts = function(_, opts)
table.insert(opts.sources, { name = "emoji" })
end,
},
-- change some telescope options and a keymap to browse plugin files
{
"nvim-telescope/telescope.nvim",
keys = {
-- add a keymap to browse plugin files
-- stylua: ignore
{
"<leader>fp",
function() require("telescope.builtin").find_files({ cwd = require("lazy.core.config").options.root }) end,
desc = "Find Plugin File",
},
},
-- change some options
opts = {
defaults = {
layout_strategy = "horizontal",
layout_config = { prompt_position = "top" },
sorting_strategy = "ascending",
winblend = 0,
},
},
},
-- add pyright to lspconfig
{
"neovim/nvim-lspconfig",
---@class PluginLspOpts
opts = {
---@type lspconfig.options
servers = {
-- pyright will be automatically installed with mason and loaded with lspconfig
pyright = {},
},
},
},
-- add tsserver and setup with typescript.nvim instead of lspconfig
{
"neovim/nvim-lspconfig",
dependencies = {
"jose-elias-alvarez/typescript.nvim",
init = function()
require("lazyvim.util").lsp.on_attach(function(_, buffer)
-- stylua: ignore
vim.keymap.set( "n", "<leader>co", "TypescriptOrganizeImports", { buffer = buffer, desc = "Organize Imports" })
vim.keymap.set("n", "<leader>cR", "TypescriptRenameFile", { desc = "Rename File", buffer = buffer })
end)
end,
},
---@class PluginLspOpts
opts = {
---@type lspconfig.options
servers = {
-- tsserver will be automatically installed with mason and loaded with lspconfig
tsserver = {},
},
-- you can do any additional lsp server setup here
-- return true if you don't want this server to be setup with lspconfig
---@type table<string, fun(server:string, opts:_.lspconfig.options):boolean?>
setup = {
-- example to setup with typescript.nvim
tsserver = function(_, opts)
require("typescript").setup({ server = opts })
return true
end,
-- Specify * to use this function as a fallback for any server
-- ["*"] = function(server, opts) end,
},
},
},
-- for typescript, LazyVim also includes extra specs to properly setup lspconfig,
-- treesitter, mason and typescript.nvim. So instead of the above, you can use:
{ import = "lazyvim.plugins.extras.lang.typescript" },
-- add more treesitter parsers
{
"nvim-treesitter/nvim-treesitter",
opts = {
ensure_installed = {
"bash",
"html",
"javascript",
"json",
"lua",
"markdown",
"markdown_inline",
"python",
"query",
"regex",
"tsx",
"typescript",
"vim",
"yaml",
},
},
},
-- since `vim.tbl_deep_extend`, can only merge tables and not lists, the code above
-- would overwrite `ensure_installed` with the new value.
-- If you'd rather extend the default config, use the code below instead:
{
"nvim-treesitter/nvim-treesitter",
opts = function(_, opts)
-- add tsx and treesitter
vim.list_extend(opts.ensure_installed, {
"tsx",
"typescript",
})
end,
},
-- the opts function can also be used to change the default opts:
{
"nvim-lualine/lualine.nvim",
event = "VeryLazy",
opts = function(_, opts)
table.insert(opts.sections.lualine_x, {
function()
return "😄"
end,
})
end,
},
-- or you can return new options to override all the defaults
{
"nvim-lualine/lualine.nvim",
event = "VeryLazy",
opts = function()
return {
--[[add your custom lualine config here]]
}
end,
},
-- use mini.starter instead of alpha
{ import = "lazyvim.plugins.extras.ui.mini-starter" },
-- add jsonls and schemastore packages, and setup treesitter for json, json5 and jsonc
{ import = "lazyvim.plugins.extras.lang.json" },
-- add any tools you want to have installed below
{
"williamboman/mason.nvim",
opts = {
ensure_installed = {
"stylua",
"shellcheck",
"shfmt",
"flake8",
},
},
},
{
"fladson/vim-kitty",
ft = "kitty",
tag = "*", -- You can select a tagged version
},
}

3
nvim/stylua.toml Normal file
View File

@@ -0,0 +1,3 @@
indent_type = "Spaces"
indent_width = 2
column_width = 120

Binary file not shown.

View File

@@ -0,0 +1,38 @@
#!/bin/bash
# ___ _____ ___ _ _____ ____ _ _
# / _ \_ _|_ _| | | ____| / ___|| |_ __ _ _ __| |_
# | | | || | | || | | _| \___ \| __/ _` | '__| __|
# | |_| || | | || |___| |___ ___) | || (_| | | | |_
# \__\_\|_| |___|_____|_____| |____/ \__\__,_|_| \__|
#
# by cerberus
# -----------------------------------------------------
# -----------------------------------------------------
# Essentials
# -----------------------------------------------------
# Load polkit agent
gnome-keyring-daemon --start --components=pkcs11,secrets,ssh &
/usr/lib/mate-polkit/polkit-mate-authentication-agent-1 &
# -----------------------------------------------------
# Configure Screens
# -----------------------------------------------------
"$HOME"/.screenlayout/screens3.sh &
# -----------------------------------------------------
# Autostart Applications
# -----------------------------------------------------
picom & # Compositor
nitrogen --restore & # Wallpaper Manager
copyq & # Clipboard Manager
flameshot & # Screenshot Tool
discord & # Discord
steam -silent & # Steam
firefox & # Firefox
youtube-music & # YT-Music
bitwarden-desktop & # Bitwarden Passwordmanager
joplin & # Note Taking
rnote & # Hand-Written Notes
"$HOME"/Documents/scripts/wacom_screen_config.sh &
# librewolf &

View File

@@ -1,28 +1,76 @@
# Qtile configuration by cerberus # Qtile configuration by cerberus
from libqtile import qtile from libqtile import qtile, bar
from libqtile.backend.wayland.inputs import InputConfig from libqtile.backend.wayland.inputs import InputConfig
from libqtile.config import Screen
""" from themes.colors import gruvbox_dark
General configuration
"""
dgroups_key_binder = None from modules.keys import keybinds, mousebinds
dgroups_app_rules = [] # type: list from modules.groups import groups, get_group_keys
follow_mouse_focus = True from modules.widgets import widgets_main, widgets_portrait, widgets_media
bring_front_click = True from modules.hooks import *
floats_kept_above = True from modules.layouts import layouts
cursor_warp = True
auto_fullscreen = True
focus_on_window_activation = "smart"
reconfigure_screens = True
auto_minimize = True
wmname = "Qtile" # Application definitions
APPS = {
"terminal": "kitty",
"browser": "firefox",
"filebrowser": "nemo",
"cli-filebrowser": "yazi",
"editor": "nvim",
}
""" # Screens
Wayland specific configuration screens = [
""" # Left screen
Screen(
top=bar.Bar(
widgets_media,
background=gruvbox_dark["bg0_hard"],
opacity=0.75,
size=32,
margin=[3, 3, 0, 3],
),
),
# Center screen
Screen(
top=bar.Bar(
widgets_main,
background=gruvbox_dark["bg0_hard"],
opacity=0.75,
size=32,
margin=[3, 3, 0, 3],
),
),
# Right screen
Screen(
top=bar.Bar(
widgets_portrait,
background=gruvbox_dark["bg0_hard"],
opacity=0.75,
size=32,
margin=[3, 3, 0, 3],
)
),
]
widget_defaults = dict(
font="Open Sans",
fontsize=22,
foreground=gruvbox_dark["fg1"],
)
# Essentials
mod = "mod4"
keys = keybinds()
keys.extend(get_group_keys(mod))
mouse = mousebinds()
groups = groups
layouts = layouts
# Wayland specific configuration
if qtile.core.name == "X11": if qtile.core.name == "X11":
term = "urvx" term = "urvx"
elif qtile.core.name == "wayland": elif qtile.core.name == "wayland":
@@ -39,3 +87,15 @@ wl_input_rules = {
wl_xcursor_theme = None wl_xcursor_theme = None
wl_xcursor_size = 18 wl_xcursor_size = 18
# General Qtile configuration
dgroups_key_binder = None
dgroups_app_rules = [] # type: list
follow_mouse_focus = True
bring_front_click = True
floats_kept_above = True
cursor_warp = True
auto_fullscreen = True
focus_on_window_activation = "smart"
reconfigure_screens = True
auto_minimize = True
wmname = "Qtile"

View File

@@ -0,0 +1,144 @@
# groups.py (überarbeitete Version)
import re
from libqtile.lazy import lazy
from libqtile.config import Group, EzKey as Key, Match, DropDown, ScratchPad
# WICHTIG: Definiere hier group_screen_map und groups
group_screen_map = {
"0": 0,
"1": 1,
"2": 1,
"3": 1,
"4": 0,
"5": 0,
"6": 0,
"7": 2,
"8": 2,
"9": 2,
"f1": 0,
"f2": 2,
"f3": 0,
"f4": 2,
"f5": 2,
"f6": 2,
"f7": 0,
"f8": 1,
"f9": 1,
"f10": 1,
"f11": 1,
"f12": 1,
}
groups = [
Group(
name="0",
label="󰓓",
matches=[Match(wm_class=re.compile(r"^(steam|Minecraft*)"))],
),
Group(name="1", label="󰲡"),
Group(name="2", label="󰲣"),
Group(name="3", label="󰲥"),
Group(name="4", label="󰲧"),
Group(name="5", label="󰲩"),
Group(name="6", label="󰲫"),
Group(name="7", label="󰲭"),
Group(name="8", label="󰲯"),
Group(name="9", label="󰲱"),
# Groups on function-keys
Group(name="f1", label="", matches=[Match(wm_class=re.compile(r"^(firefox)$"))]),
Group(name="f2", label="", matches=[Match(wm_class="discord")]),
Group(name="f3", label="", matches=[Match(wm_class=re.compile(r"^(joplin)$"))]),
Group(
name="f4",
label="",
matches=[Match(wm_class=re.compile(r"^(com.github.th_ch.youtube_music)$"))],
),
Group(name="f5", label="󱦹", matches=[Match(wm_class="rnote")]),
Group(name="f6", label="󰟵", matches=[Match(wm_class="bitwarden")]),
Group(name="f7", label=" 󰣀", matches=[Match(wm_class=re.compile(r"^(XPipe)$"))]),
Group(name="f8", label="󱊲"),
Group(name="f9", label="󱊳"),
Group(name="f10", label="󱊴"),
Group(name="f11", label="󱊵"),
Group(name="f12", label="󱊶"),
]
# Füge die Scratchpad-Gruppe zur Gruppenliste hinzu
groups.append(
ScratchPad(
"scratchpad",
[
DropDown(
"term",
"kitty",
width=0.4,
height=0.5,
x=0.3,
y=0.25,
opacity=1,
on_focus_lost_hide=True,
),
DropDown(
"calc",
"qalculate-gtk",
width=0.3,
height=0.6,
x=0.35,
y=0.2,
opacity=1,
on_focus_lost_hide=False,
),
],
)
)
def go_to_group(name: str):
def _inner(qtile):
screen = group_screen_map.get(name, 0)
if len(qtile.screens) <= 2:
qtile.groups_map[name].toscreen()
else:
qtile.focus_screen(screen)
qtile.groups_map[name].toscreen()
return _inner
def go_to_group_and_move_window(name: str):
def _inner(qtile):
screen = group_screen_map.get(name, 0)
qtile.current_window.togroup(name, switch_group=False)
if len(qtile.screens) > 2:
qtile.focus_screen(screen)
qtile.groups_map[name].toscreen()
return _inner
def get_group_keys(mod: str) -> list:
"""
Diese Funktion erstellt und gibt alle Key-Bindings für die Gruppen zurück.
Sie nimmt den Modifier-Key (z.B. "M") als Argument.
"""
keys = []
# Fügt Keys für reguläre Gruppen und F-Tasten-Gruppen hinzu
for group in groups:
# Hier wird der Name der Gruppe als Key verwendet, außer bei Scratchpads
if group.name != "scratchpad":
# Normale Gruppen wechseln
keys.append(
Key(f"M-{group.name}", lazy.function(go_to_group(group.name))),
)
# Fenster in Gruppe verschieben
keys.append(
Key(
f"M-S-{group.name}",
lazy.function(go_to_group_and_move_window(group.name)),
),
)
return keys

View File

@@ -0,0 +1,31 @@
import os.path
import subprocess
from libqtile import hook, qtile
from libqtile.config import Match
# Autostart
@hook.subscribe.startup_once
def autostart():
script = "~/.config/qtile/assets/scripts/autostart.sh"
home = os.path.expanduser(script)
subprocess.Popen([home])
@hook.subscribe.startup_complete
def go_to_group_1():
qtile.focus_screen(0)
qtile.groups_map["1"].toscreen()
"""
Some clients won't start fullscreen (exclusive to wayland)
With this function we force clients defined in FULLSCREEN_RULES to enter fullscreen
"""
FULLSCREEN_RULES = [Match(wm_class="flameshot")]
@hook.subscribe.client_managed
def force_fullscreen(client) -> None:
if any(client.match(rule) for rule in FULLSCREEN_RULES):
client.fullscreen = True

View File

@@ -1,30 +1,19 @@
from libqtile.lazy import lazy from libqtile.lazy import lazy
from libqtile.config import EzKey as Key from libqtile.config import EzKey as Key
from libqtile.config import EzClick as Click, EzDrag as Drag
from modules.groups import groups
from config import apps, modifier_keys
keys = [ def keybinds():
# from ..config import APPS
keys = (
[
# Focus manipulation # Focus manipulation
Key( Key("M-h", lazy.layout.left(), desc="Move focus to the left"),
"M-h", Key("M-l", lazy.layout.right(), desc="Move focus to the right"),
lazy.layout.left(), Key("M-j", lazy.layout.down(), desc="Move focus to the down"),
desc="Move focus to the left", Key("M-k", lazy.layout.up(), desc="Move focus to the up"),
),
Key(
"M-l",
lazy.layout.right(),
desc="Move focus to the right",
),
Key(
"M-j",
lazy.layout.down(),
desc="Move focus to the down",
),
Key(
"M-k",
lazy.layout.up(),
desc="Move focus to the up",
),
# Window manipulation # Window manipulation
Key( Key(
"M-S-h", "M-S-h",
@@ -36,24 +25,125 @@ keys = [
lazy.layout.swap_right(), lazy.layout.swap_right(),
desc="Move window to the right", desc="Move window to the right",
), ),
Key("M-S-j", lazy.layout.shuffle_down(), desc="Move window down"),
Key("M-S-k", lazy.layout.shuffle_up(), desc="Move window up"),
Key("M-S-i", lazy.layout.shrink(), desc="Increase window size"),
Key("M-S-m", lazy.layout.grow(), desc="Decrease window size"),
Key("M-c", lazy.window.kill(), desc="Closes window"),
# Layout manipulation
Key( Key(
"M-S-j", "M-n",
lazy.layout.shuffle_down(), lazy.layout.normalize(),
desc="Move window down", desc="Normalize all window sizes",
),
Key("M-S-n", lazy.layout.reset(), desc="Resets all window sizes"),
Key(
"M-t",
lazy.window.toggle_floating(),
desc="Toggles between floating and tiled state of a window",
), ),
Key( Key(
"M-S-k", "M-o",
lazy.layout.shuffle_up(), lazy.layout.maximize(),
desc="Move window up", desc="Maximizes the window in the current layot",
), ),
Key( Key(
"M-S-i", "M-f",
lazy.layout.shrink(), lazy.window.toggle_fullscreen(),
desc="Increase window size", desc="Toggles wiondow between tiled/floating and fullscreen",
),
Key("M-<Tab>", lazy.next_layout(), desc="Switches between layouts"),
Key("M-C-r", lazy.reload_config(), desc="Reload config"),
# Audio and media control
Key("<F86AudioMute>", lazy.spawn("pamixer -t"), desc="Mutes Audio"),
Key(
"<XF86AudioLowerVolume>",
lazy.spawn("pamixer -d 2"),
desc="Lower Audio Volume",
), ),
Key( Key(
"M-S-m", "<XF86AudioRaiseVolume>",
lazy.layout.grow(), lazy.spawn("pamixer -i 2"),
desc="Decrease window size", desc="Raise Audio Volume",
), ),
Key(
"<XF86AudioPrev>",
lazy.spawn("playerctl previous"),
desc="Play Previous Media",
),
Key(
"<XF86AudioNext>",
lazy.spawn("playerctl next"),
desc="Play Next Media",
),
Key(
"<XF86AudioPlay>",
lazy.spawn("playerctl play-pause"),
desc="Toggle Play/Pause",
),
# Rofi
Key(
"M-r",
lazy.spawn("rofi -show drun -show-icons"),
desc="Spawns Rofi",
),
Key(
"A-<Tab>",
lazy.spawn("rofi -show window -show-icons"),
desc="Tab Windows",
),
# Scratchpads
Key(
"C-1",
lazy.group["scratchpad"].dropdown_toggle("term"),
desc="Toggles terminal scratchpad",
),
Key(
"C-2",
lazy.group["scratchpad"].dropdown_toggle("calc"),
desc="Calculator in scratchpad",
),
# Application shortcuts
Key(
"M-e",
lazy.spawn(APPS["filebrowser"]),
desc="Launches filebrowser",
),
Key("M-b", lazy.spawn(APPS["browser"])),
Key("M-<Return>", lazy.spawn(APPS["terminal"])),
],
)
for group in groups:
# Hier wird der Name der Gruppe als Key verwendet, außer bei Scratchpads
if group.name != "scratchpad":
# Normale Gruppen wechseln
keys.append(
Key(f"M-{group.name}", lazy.function(go_to_group(group.name))),
)
# Fenster in Gruppe verschieben
keys.append(
Key(
f"M-S-{group.name}",
lazy.function(go_to_group_and_move_window(group.name)),
),
)
return keys
def mousebinds():
mouse = [
Drag(
"M-1",
lazy.window.set_position_floating(),
start=lazy.window.get_position(),
),
Drag(
"M-3",
lazy.window.set_size_floating(),
start=lazy.window.get_size(),
),
Click("M-2", lazy.window.bring_to_front()),
] ]
return mouse

View File

@@ -0,0 +1,53 @@
from libqtile import layout
from libqtile.config import Match
LAYOUT_DEFAULTS = dict(
margin=3,
border_width=0,
grow_amount=2,
)
floating_layout_defaults = LAYOUT_DEFAULTS.copy()
layouts = [
layout.MonadTall(
name="Monad",
auto_maximize=True,
change_ratio=0.05,
change_size=20,
ratio=0.55,
min_ratio=0.30,
max_ratio=0.75,
single_border_width=0,
**LAYOUT_DEFAULTS,
),
layout.VerticalTile(
**LAYOUT_DEFAULTS,
),
]
floating_layout = layout.Floating(
float_rules=[
*layout.Floating.default_float_rules,
Match(wm_class="confirmreset"), # gitk
Match(wm_class="makebranch"), # gitk
Match(wm_class="maketag"), # gitk
Match(wm_class="ssh-askpass"), # ssh-askpass
Match(wm_class="nm-connection-editor"), # networkmanager
Match(title="branchdialog"), # gitk
Match(title="pinentry"), # GPG key password entry
Match(title="FloatWindow"),
Match(wm_class="qalculate-qt"),
Match(wm_class="copyq"),
Match(wm_class="nitrogen"),
Match(wm_class="nemo-preview-start"),
Match(wm_class="wireguird"),
Match(wm_class="blueman-manager"),
Match(wm_class="pavucontrol"),
Match(wm_class="org.gnome.FileRoller"),
Match(wm_class="lximage-qt"),
Match(wm_class="matplotlib"),
],
**floating_layout_defaults,
)

View File

@@ -1 +1,208 @@
from libqtile import widget from libqtile.lazy import lazy
from qtile_extras import widget
from qtile_extras.widget.groupbox2 import GroupBoxRule
from config import widget_defaults
from themes.colors import gruvbox_dark
from plugins.notifications import Notifier
from popups.start_menu import start_menu
from popups.powermenu import power_menu
from popups.calendar import calendar
from popups.volume_notification import VOL_POPUP
from popups.mpris2_layout import MPRIS2_LAYOUT
def get_groupbox_rules(monitor_specific=True):
# Base rules applied to all GroupBoxes
rules = [
GroupBoxRule(text_colour=gruvbox_dark["bg3"]).when(
focused=False, occupied=True
),
GroupBoxRule(text_colour=gruvbox_dark["aqua"]).when(
focused=False, occupied=False
),
GroupBoxRule(text_colour=gruvbox_dark["fg3"]).when(focused=True),
GroupBoxRule(text_colour=gruvbox_dark["red"]).when(
focused=False, occupied=True, urgent=True
),
GroupBoxRule(visible=False).when(focused=False, occupied=False),
]
# Add extra rule for a specific monitor (e.g., show "X" as label)
if monitor_specific:
rules.append(GroupBoxRule(text=""))
return rules
widgets_media = [
widget.TextBox(
text="",
fontsize=24,
foreground=gruvbox_dark["blue"],
mouse_callbacks={"Button1": lazy.function(start_menu)},
),
widget.GroupBox2(
padding=6,
fontsize=22,
font="Open Sans",
center_aligned=True,
visible_groups=[
"4",
"5",
"6",
"f1",
"f7",
"f3",
],
hide_unused=True,
rules=get_groupbox_rules(monitor_specific=False),
),
widget.Spacer(length=20),
widget.Mpris2(
name="mpris2",
width=350,
scroll=True,
scroll_clear=True,
foreground=gruvbox_dark["fg1"],
format="{xesam:title} - {xesam:artist}",
paused_text="{track} ",
popup_layout=MPRIS2_LAYOUT,
poll_interval=15,
popup_show_args={
"relative_to": 2,
"relative_to_bar": True,
"y": 3,
},
mouse_callbacks={
"Button1": lazy.widget["mpris2"].toggle_player(),
},
),
widget.Spacer(),
widget.Clock(mouse_callbacks={"Button1": lazy.function(calendar)}),
widget.Spacer(length=2),
widget.TextBox(
fontsize=20,
text="",
mouse_callbacks={"Button1": lazy.function(power_menu)},
),
]
widgets_main = [
widget.TextBox(
text="",
fontsize=24,
foreground=gruvbox_dark["blue"],
mouse_callbacks={"Button1": lazy.function(start_menu)},
),
widget.GroupBox2(
padding=5,
fontsize=22,
font="Open Sans",
center_aligned=True,
visible_groups=[
"1",
"2",
"3",
"0",
"f8",
"f9",
"f10",
"f11",
"f12",
],
hide_unused=True,
rules=get_groupbox_rules(monitor_specific=False),
),
widget.Spacer(),
widget.Systray(
icon_size=21,
),
widget.Spacer(length=6),
widget.Clock(mouse_callbacks={"Button1": lazy.function(calendar)}),
widget.Spacer(length=2),
widget.TextBox(
font="Open Sans",
fontsize=20,
text="",
mouse_callbacks={"Button1": lazy.function(power_menu)},
),
widget.PulseVolumeExtra(
mode="popup",
fmt="",
popup_layout=VOL_POPUP,
popup_hide_timeout=3,
popup_show_args={"relative_to": 8, "y": -70},
),
]
widgets_portrait = [
widget.TextBox(
text="",
fontsize=24,
foreground=gruvbox_dark["blue"],
mouse_callbacks={"Button1": lazy.function(start_menu)},
),
widget.GroupBox2(
padding=6,
fontsize=22,
margin=7,
font="Open Sans",
center_aligned=True,
visible_groups=["7", "8", "9", "f2", "f4", "f5", "f6"],
hide_unused=True,
rules=get_groupbox_rules(monitor_specific=False),
),
widget.Spacer(),
widget.WidgetBox(
fontsize=22,
text_closed="󱤟",
text_open="󱤠",
widgets=[
widget.Memory(
format="{MemPercent}%",
font="Open Sans",
),
widget.CPU(
format="{load_percent}%",
font="Open Sans",
),
],
),
widget.Spacer(length=6),
widget.Clock(mouse_callbacks={"Button1": lazy.function(calendar)}),
widget.Spacer(length=2),
widget.TextBox(
font="Open Sans",
fontsize=20,
text="",
mouse_callbacks={"Button1": lazy.function(power_menu)},
),
]
notifier = Notifier(
x=1155,
y=38,
width=250,
height=96,
format="<b>{summary}</b>\n{app_name}\n{body}",
# file_name='/home/cerberus/.config/qtile/normal.png', # Not working
foreground=gruvbox_dark["fg1"],
background=(
gruvbox_dark["bg0_hard"],
gruvbox_dark["bg0_hard"],
gruvbox_dark["orange"],
),
horizontal_padding=8,
vertical_padding=8,
opacity=0.65,
border_width=0,
font="Open Sans",
font_size=16,
overflow="truncate",
fullscreen="queue",
screen=1,
# actions=True,
# wrap=True
)

135
qtile/popups/calendar.py Normal file
View File

@@ -0,0 +1,135 @@
import subprocess
from libqtile import qtile
from qtile_extras import widget
from qtile_extras.popup.toolkit import (PopupRelativeLayout,
PopupWidget,
)
from res.themes.colors import gruvbox_dark
# https://discord.com/channels/955163559086665728/1166312212223250482/1322614846155657370
# check for this PR to change back the code with the message contents to the prev code of the widget:
# PopupWidget(
# pos_x=0.051,
# pos_y=0.415,
# height=0.6,
# width=0.9,
# widget=widget.GenPollCommand(
# cmd="cal",
# shell=True,
# font='mono',
# fontsize=20,
# markup=False,
# # background=gruvbox_dark["blue"],
# )
def parse_cal():
process = subprocess.run(
"cal",
capture_output=True,
text=True,
)
body = process.stdout.strip()
lines = body.splitlines()
maxlen = max(len(l) for l in lines)
output = []
for line in body.splitlines():
if len(line) < maxlen:
line += " " * (maxlen - len(line))
output.append(line)
return "\n".join(output).strip("\n")
def calendar(qtile):
layout = PopupRelativeLayout(
qtile,
rows=7,
cols=9,
width=300,
height=310,
opacity=0.8,
hide_on_mouse_leave=True,
close_on_click=False,
border_width=0,
background=gruvbox_dark["bg0_soft"],
controls=[
PopupWidget(
pos_x=0,
pos_y=0,
height=0.2,
width=0.9,
v_align="middle",
h_align="center",
widget=widget.Wttr(
fontsize=40,
format='%c'
)
),
PopupWidget(
pos_x=0.3,
pos_y=0.05,
height=0.05,
width=0.9,
v_align="middle",
h_align="center",
widget=widget.Wttr(
font='Open Sans Bold',
fontsize=18,
format='Actual: %t'
)
),
PopupWidget(
pos_x=0.3,
pos_y=0.12,
height=0.05,
width=0.9,
widget=widget.Wttr(
font='Open Sans',
fontsize=14,
format='Feels: %f'
)
),
PopupWidget(
pos_x=0.05,
pos_y=0.2,
height=0.05,
width=0.9,
widget=widget.Wttr(
font='Open Sans',
fontsize=14,
format='Wind: %w Prec: %p'
)
),
PopupWidget(
pos_x=0.05,
pos_y=0.25,
height=0.11,
width=0.9,
widget=widget.Wttr(
font='Open Sans Bold',
fontsize=14,
format='City: %l', # \nFeel;%f Wind: %w'
)
),
PopupWidget(
pos_x=0.051,
pos_y=0.38,
height=0.6,
width=0.9,
widget=widget.GenPollText(
func=parse_cal,
font='mono',
fontsize=20,
markup=False,
)
),
]
)
layout.show(relative_to=3,
relative_to_bar=True,
y=3,
x=-3,
)

31
qtile/popups/monitor.py Normal file
View File

@@ -0,0 +1,31 @@
from libqtile import qtile
from qtile_extras import widget
from qtile_extras.popup.toolkit import (
PopupRelativeLayout,
PopupWidget,
)
from res.themes.colors import gruvbox_dark
def monitor(qtile):
layout = PopupRelativeLayout(
qtile,
rows=7,
cols=9,
width=600,
height=420,
opacity=0.8,
hide_on_mouse_leave=True,
close_on_click=False,
border_width=0,
background=gruvbox_dark["bg0_soft"],
controls=[],
)
layout.show(
relative_to=5,
relative_to_bar=True,
# y=3,
# x=-3,
)

View File

@@ -0,0 +1,125 @@
from res.themes.colors import gruvbox_dark
from qtile_extras.popup.toolkit import (
PopupRelativeLayout,
PopupImage,
PopupText,
PopupSlider
)
image='/home/cerberus/.config/qtile/res/images/no_cover.svg'
MPRIS2_LAYOUT = PopupRelativeLayout(
None,
width=400,
height=200,
opacity=0.7,
background=gruvbox_dark["bg0_soft"],
hide_on_mouse_leave=True,
controls=[
PopupText(
"",
name="title",
font='Open Sans Bold',
fontsize=18,
pos_x=0.35,
pos_y=0.1,
width=0.55,
height=0.14,
h_align="left",
v_align="top",
),
PopupText(
"",
name="artist",
font='Open Sans Medium',
fontsize=14,
pos_x=0.35,
pos_y=0.24,
width=0.55,
height=0.14,
h_align="left",
v_align="middle",
),
PopupText(
"",
name="album",
font='Open Sans',
fontsize=14,
pos_x=0.35,
pos_y=0.38,
width=0.55,
height=0.14,
h_align="left",
v_align="bottom",
),
PopupImage(
name="artwork",
filename=image,
pos_x=0.1,
pos_y=0.1,
width=0.21,
height=0.42,
),
PopupSlider(name="progress", pos_x=0.1, pos_y=0.6, width=0.8, height=0.1, marker_size=0),
PopupText(
name="previous",
text='󰙤',
fontsize=30,
mask=True,
pos_x=0.125,
pos_y=0.8,
width=0.15,
height=0.1,
v_align="middle",
h_align="center",
highlight_method='text',
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
),
PopupText(
name="play_pause",
text='󰐎',
fontsize=30,
mask=True,
pos_x=0.325,
pos_y=0.8,
width=0.15,
height=0.1,
v_align="middle",
h_align="center",
highlight_method='text',
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
),
PopupText(
name="stop",
text='',
fontsize=30,
mask=True,
pos_x=0.525,
pos_y=0.8,
width=0.15,
height=0.1,
v_align="middle",
h_align="center",
highlight_method='text',
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
),
PopupText(
name="next",
text='󰙢',
fontsize=30,
mask=True,
pos_x=0.725,
pos_y=0.8,
width=0.15,
height=0.1,
v_align="middle",
h_align="center",
highlight_method='text',
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
),
],
close_on_click=False,
)

48
qtile/popups/network.py Normal file
View File

@@ -0,0 +1,48 @@
from libqtile import qtile
from libqtile.lazy import lazy
from res.themes.colors import gruvbox_dark
from qtile_extras.popup.menu import (
PopupMenu,
PopupMenuItem,
PopupMenuSeparator,
)
items=[
PopupMenuItem(
show_icon=False,
text='󰛳 Network Manager',
font='Open Sans',
fontsize=16,
can_focus=True,
highlight_method='text',
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
mouse_callbacks={"Button1": lazy.spawn("nm-connection-editor")},
),
PopupMenuSeparator(),
PopupMenuItem(
show_icon=False,
text='󰐚 Wireguard',
font='Open Sans',
fontsize=16,
highlight_method='text',
can_focus=True,
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
mouse_callbacks={"Button1": lazy.spawn("wireguird")},
)
]
def network_menu(qtile):
layout = PopupMenu.generate(
qtile,
pos_x=100,
pos_y=100,
width=225,
opacity=0.7,
menuitems=items,
background=gruvbox_dark["bg0_soft"]
)
layout.show(relative_to=1, relative_to_bar=True, y=136, x=220)

70
qtile/popups/powermenu.py Normal file
View File

@@ -0,0 +1,70 @@
from libqtile.lazy import lazy
from res.themes.colors import gruvbox_dark
from qtile_extras.popup.toolkit import (
PopupRelativeLayout,
PopupText,
)
# qtile/resources/themes/colors.py
def power_menu(qtile):
layout = PopupRelativeLayout(
qtile,
width=800,
height=250,
opacity=0.7,
# border=gruvbox_dark["red"],
# border_width=3,
background=gruvbox_dark["bg0_soft"],
initial_focus=None,
controls=[
PopupText(
# Lock betterlockscreen --lock blur
text="",
fontsize=80,
pos_y=0,
pos_x=0.1,
width=0.2,
height=1,
mouse_callbacks={"Button1": lazy.spawn("betterlockscreen --lock blur")},
highlight_method='text',
highlight=gruvbox_dark["green"],
),
PopupText(
# Hybrid Sleep systemctl hybrid-sleep
text="󰒲",
fontsize=80,
pos_y=0,
pos_x=0.32,
width=0.2,
height=1,
mouse_callbacks={"Button1": lazy.spawn("systemctl hybrid-sleep")},
highlight_method='text',
highlight=gruvbox_dark["yellow"],
),
PopupText(
# Hibernate systemctl hibernate
text="",
fontsize=80,
pos_y=0,
pos_x=0.55,
width=0.2,
height=1,
mouse_callbacks={"Button1": lazy.spawn("systemctl hibernate")},
highlight_method='text',
highlight=gruvbox_dark["orange"],
),
PopupText(
# Power off systemctl poweroff
text="",
fontsize=80,
pos_y=0,
pos_x=0.8,
width=0.2,
height=1,
mouse_callbacks={"Button1": lazy.spawn("systemctl poweroff")},
highlight_method='text',
highlight=gruvbox_dark["red"],
),
],
)
layout.show(relative_to=5, relative_to_bar=True, hide_on_timeout=5)

View File

@@ -0,0 +1,90 @@
from pydoc import importfile
from libqtile import qtile
from libqtile.lazy import lazy
from res.themes.colors import gruvbox_dark
from qtile_extras.popup.toolkit import (
PopupRelativeLayout,
PopupImage,
PopupText,
)
def powermenu_2(qtile):
layout = PopupRelativeLayout(
qtile,
width=170,
height=50,
opacity=0.7,
hide_on_mouse_leave=True,
close_on_click=False,
border_width=0,
background=gruvbox_dark["bg0_soft"],
controls=[
PopupText(
# Lock
text='',
fontsize=22,
pos_x=0.07,
pos_y=0.05,
height=0.8,
width=0.2,
can_focus=True,
v_align="middle",
h_align="center",
highlight_method='text',
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
mouse_callbacks={"Button1": lazy.spawn("betterlockscreen --lock blur")},
),
PopupText(
# Reboot
text='',
fontsize=22,
pos_x=0.3,
pos_y=0.05,
height=0.8,
width=0.2,
can_focus=True,
v_align="middle",
h_align="center",
highlight_method='text',
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
mouse_callbacks={"Button1": lazy.spawn("systemctl reboot")},
),
PopupText(
# Suspend
text='󰒲',
fontsize=22,
pos_x=0.54,
pos_y=0.05,
height=0.8,
width=0.2,
can_focus=True,
v_align="middle",
h_align="center",
highlight_method='text',
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
mouse_callbacks={"Button1": lazy.spawn("systemctl suspend")},
),
PopupText(
# Shutdown
text='',
fontsize=22,
pos_x=0.78,
pos_y=0.05,
height=0.8,
width=0.2,
can_focus=True,
v_align="middle",
h_align="center",
highlight_method='text',
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
mouse_callbacks={"Button1": lazy.spawn("systemctl poweroff")},
),
]
)
layout.show(relative_to=1, relative_to_bar=True, y=136, x=30)

59
qtile/popups/settings.py Normal file
View File

@@ -0,0 +1,59 @@
from libqtile import qtile
from libqtile.lazy import lazy
from res.themes.colors import gruvbox_dark
from qtile_extras.popup.menu import (
PopupMenu,
PopupMenuItem,
PopupMenuSeparator,
)
items = [
PopupMenuItem(# Wallpaper setting
show_icon=False,
text=' 󰸉 Nitrogen Wallpaper',
font='Open Sans',
fontsize=16,
can_focus=True,
highlight_method='text',
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
mouse_callbacks={"Button1": lazy.spawn("nitrogen")},
),
PopupMenuSeparator(),
PopupMenuItem(# Arandr
show_icon=False,
text=' 󰹑 Arandr Display',
font='Open Sans',
fontsize=16,
can_focus=True,
highlight_method='text',
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
mouse_callbacks={"Button1": lazy.spawn("arandr")},),
PopupMenuSeparator(),
PopupMenuItem(# VS-Code qtile config
show_icon=False,
text='  Qtile Config',
font='Open Sans',
fontsize=16,
can_focus=True,
highlight_method='text',
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
mouse_callbacks={"Button1": lazy.spawn("code /home/cerberus/.config/")},),
]
def settings(qtile):
layout = PopupMenu.generate(
qtile,
pos_x=100,
pos_y=100,
width=225,
opacity=0.7,
menuitems=items,
background=gruvbox_dark["bg0_soft"]
)
layout.show(relative_to=1, relative_to_bar=True, y=75, x=325)

186
qtile/popups/start_menu.py Normal file
View File

@@ -0,0 +1,186 @@
from libqtile import qtile
from libqtile.lazy import lazy
from qtile_extras import widget
from qtile_extras.popup.toolkit import (
PopupRelativeLayout,
PopupImage,
PopupText,
PopupWidget,
)
from res.themes.colors import gruvbox_dark
from popups.settings import settings
from popups.network import network_menu
from popups.powermenu_sub import powermenu_2
from popups.monitor import monitor
def start_menu(qtile):
layout = PopupRelativeLayout(
qtile,
width=350,
height=150,
opacity=0.7,
hide_on_mouse_leave=True,
close_on_click=False,
border_width=0,
background=gruvbox_dark["bg0_soft"],
controls=[
# Row 1
PopupImage(
# Qtile logo
pos_x=0,
pos_y=0,
height=0.3,
width=0.3,
mask=True,
colour=gruvbox_dark["blue"],
filename="/home/cerberus/.config/qtile/res/images/standby_rotated.png",
),
PopupWidget(
# Welcome banner, fetching user name from $USER
pos_x=0.241,
pos_y=0.12,
height=0.15,
width=0.8,
widget=widget.GenPollCommand(
foreground=gruvbox_dark["orange"],
cmd="echo Welcome $USER",
shell=True,
font="Open Sans Bold",
fontsize=20,
width=250,
scroll=True,
),
),
# PopupText(
# # Steam Gamemode (Controller)
# pos_x=0,
# pos_y=0,
# width=0.3,
# height=0.3,
# can_focus=True,
# v_align="middle",
# h_align="center",
# background=gruvbox_dark["green"],
# ),
PopupText(
# Steam Gamemode (Controller)
text="󰊴",
fontsize=34,
pos_x=0.271,
pos_y=0.4,
width=0.34,
height=0.2,
can_focus=True,
v_align="middle",
h_align="center",
highlight_method="text",
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
background=gruvbox_dark["bg2"],
mouse_callbacks={
"Button1": lazy.spawn("steam steam://open/bigpicture")
},
),
PopupText(
# Settings
text="",
fontsize=22,
pos_x=0.631,
pos_y=0.4,
width=0.34,
height=0.2,
can_focus=True,
v_align="middle",
h_align="center",
highlight_method="text",
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
background=gruvbox_dark["bg2"],
mouse_callbacks={"Button1": lazy.function(settings)},
),
PopupText(
# Power-Menu Popup
text="󱖘",
fontsize=24,
pos_x=0.035,
pos_y=0.7,
width=0.22,
height=0.2,
can_focus=True,
v_align="middle",
h_align="center",
highlight_method="text",
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
background=gruvbox_dark["bg2"],
mouse_callbacks={"Button1": lazy.function(powermenu_2)},
),
PopupText(
# Bluetooth
text="󰨇",
fontsize=22,
pos_x=0.271,
pos_y=0.7,
width=0.22,
height=0.2,
can_focus=True,
v_align="middle",
h_align="center",
highlight_method="text",
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
background=gruvbox_dark["bg2"],
mouse_callbacks={"Button1": lazy.function(monitor)},
),
PopupText(
# Network Popup
text="󰌘",
fontsize=24,
pos_x=0.511,
pos_y=0.7,
width=0.22,
height=0.2,
can_focus=True,
v_align="middle",
h_align="center",
highlight_method="text",
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
background=gruvbox_dark["bg2"],
mouse_callbacks={"Button1": lazy.function(network_menu)},
),
PopupText(
# Audiocontrol
text="",
fontsize=24,
pos_x=0.75,
pos_y=0.7,
width=0.22,
height=0.2,
can_focus=True,
v_align="middle",
h_align="center",
highlight_method="text",
foreground=gruvbox_dark["fg0"],
highlight=gruvbox_dark["green"],
background=gruvbox_dark["bg2"],
mouse_callbacks={"Button1": lazy.spawn("pavucontrol")},
),
PopupText(
# "extras"
text="extras",
font="Open Sans Bold",
foreground=gruvbox_dark["fg2"],
fontsize=10,
pos_x=0.055,
pos_y=0.57,
height=0.05,
width=0.15,
),
],
)
layout.show(relative_to=1, relative_to_bar=True, y=3, x=3)

View File

@@ -0,0 +1,40 @@
from res.themes.colors import gruvbox_dark
from qtile_extras.popup.toolkit import (
PopupRelativeLayout,
PopupText,
PopupSlider
)
VOL_POPUP = PopupRelativeLayout(
width=150,
height=150,
opacity=0.7,
background=gruvbox_dark["bg0_soft"],
controls=[
PopupText(
text="",
fontsize=60,
foreground=gruvbox_dark["fg1"],
pos_x=0,
pos_y=0,
height=0.8,
width=0.8,
v_align="middle",
h_align="center",
),
PopupSlider(
name="volume",
pos_x=0.1,
pos_y=0.7,
width=0.8,
height=0.2,
colour_below=gruvbox_dark["blue"],
bar_border_margin=1,
bar_size=8,
marker_size=0,
end_margin=0,
),
],
)

Binary file not shown.

25
qtile/themes/colors.py Normal file
View File

@@ -0,0 +1,25 @@
# --------------------------------------------------------
# Gruvbox Dark Theme Colors
# --------------------------------------------------------
gruvbox_dark = {
"bg0_hard": "#1d2021", # Background, hard
"bg0_soft": "#32302f", # Background, soft
"bg0_normal": "#282828", # Background, normal
"bg1": "#3c3836", # Secondary background
"bg2": "#504945", # Background, darker
"bg3": "#665c54", # Background, lighter
"bg4": "#7c6f64", # Background, lightest
"fg0": "#fbf1c7", # Foreground, light
"fg1": "#ebdbb2", # Foreground, normal
"fg2": "#d5c4a1", # Foreground, slightly dark
"fg3": "#bdae93", # Foreground, dark
"red": "#cc241d", # Red
"orange": "#d65d0e", # Orange
"yellow": "#d79921", # Yellow
"green": "#98971a", # Green
"aqua": "#689d6a", # Aqua
"blue": "#458588", # Blue
"purple": "#b16286" # Purple
}

View File

View File

@@ -1,221 +0,0 @@
# A TOML linter such as https://taplo.tamasfe.dev/ can use this schema to validate your config.
# If you encounter any issues, please make an issue at https://github.com/yazi-rs/schemas.
"$schema" = "https://yazi-rs.github.io/schemas/yazi.json"
[manager]
ratio = [ 2, 3, 3 ]
sort_by = "alphabetical"
sort_sensitive = false
sort_reverse = false
sort_dir_first = true
sort_translit = false
linemode = "size"
show_hidden = false
show_symlink = true
scrolloff = 5
mouse_events = [ "click", "scroll" ]
title_format = "Yazi: {cwd}"
[preview]
wrap = "no"
tab_size = 2
max_width = 600
max_height = 900
cache_dir = ""
image_delay = 30
image_filter = "triangle"
image_quality = 75
sixel_fraction = 15
ueberzug_scale = 1
ueberzug_offset = [ 0, 0, 0, 0 ]
[opener]
edit = [
{ run = '${EDITOR:-vi} "$@"', desc = "$EDITOR", block = true, for = "unix" },
{ run = 'code %*', orphan = true, desc = "code", for = "windows" },
{ run = 'code -w %*', block = true, desc = "code (block)", for = "windows" },
]
open = [
{ run = 'xdg-open "$1"', desc = "Open", for = "linux" },
{ run = 'open "$@"', desc = "Open", for = "macos" },
{ run = 'start "" "%1"', orphan = true, desc = "Open", for = "windows" },
{ run = 'termux-open "$1"', desc = "Open", for = "android" },
]
reveal = [
{ run = 'xdg-open "$(dirname "$1")"', desc = "Reveal", for = "linux" },
{ run = 'open -R "$1"', desc = "Reveal", for = "macos" },
{ run = 'explorer /select,"%1"', orphan = true, desc = "Reveal", for = "windows" },
{ run = 'termux-open "$(dirname "$1")"', desc = "Reveal", for = "android" },
{ run = '''exiftool "$1"; echo "Press enter to exit"; read _''', block = true, desc = "Show EXIF", for = "unix" },
]
extract = [
{ run = 'ya pub extract --list "$@"', desc = "Extract here", for = "unix" },
{ run = 'ya pub extract --list %*', desc = "Extract here", for = "windows" },
]
play = [
{ run = 'mpv --force-window "$@"', orphan = true, for = "unix" },
{ run = 'mpv --force-window %*', orphan = true, for = "windows" },
{ run = '''mediainfo "$1"; echo "Press enter to exit"; read _''', block = true, desc = "Show media info", for = "unix" },
]
[open]
rules = [
# Folder
{ name = "*/", use = [ "edit", "open", "reveal" ] },
# Text
{ mime = "text/*", use = [ "edit", "reveal" ] },
# Image
{ mime = "image/*", use = [ "open", "reveal" ] },
# Media
{ mime = "{audio,video}/*", use = [ "play", "reveal" ] },
# Archive
{ mime = "application/{zip,rar,7z*,tar,gzip,xz,zstd,bzip*,lzma,compress,archive,cpio,arj,xar,ms-cab*}", use = [ "extract", "reveal" ] },
# JSON
{ mime = "application/{json,ndjson}", use = [ "edit", "reveal" ] },
{ mime = "*/javascript", use = [ "edit", "reveal" ] },
# Empty file
{ mime = "inode/empty", use = [ "edit", "reveal" ] },
# Fallback
{ name = "*", use = [ "open", "reveal" ] },
]
[tasks]
micro_workers = 10
macro_workers = 10
bizarre_retry = 3
image_alloc = 536870912 # 512MB
image_bound = [ 0, 0 ]
suppress_preload = false
[plugin]
fetchers = [
# Mimetype
{ id = "mime", name = "*", run = "mime", prio = "high" },
]
spotters = [
{ name = "*/", run = "folder" },
# Code
{ mime = "text/*", run = "code" },
{ mime = "application/{mbox,javascript,wine-extension-ini}", run = "code" },
# Image
{ mime = "image/{avif,hei?,jxl,svg+xml}", run = "magick" },
{ mime = "image/*", run = "image" },
# Video
{ mime = "video/*", run = "video" },
# Fallback
{ name = "*", run = "file" },
]
preloaders = [
# Image
{ mime = "image/{avif,hei?,jxl,svg+xml}", run = "magick" },
{ mime = "image/*", run = "image" },
# Video
{ mime = "video/*", run = "video" },
# PDF
{ mime = "application/pdf", run = "pdf" },
# Font
{ mime = "font/*", run = "font" },
{ mime = "application/ms-opentype", run = "font" },
]
previewers = [
{ name = "*/", run = "folder", sync = true },
# Code
{ mime = "text/*", run = "code" },
{ mime = "application/{mbox,javascript,wine-extension-ini}", run = "code" },
# JSON
{ mime = "application/{json,ndjson}", run = "json" },
# Image
{ mime = "image/{avif,hei?,jxl,svg+xml}", run = "magick" },
{ mime = "image/*", run = "image" },
# Video
{ mime = "video/*", run = "video" },
# PDF
{ mime = "application/pdf", run = "pdf" },
# Archive
{ mime = "application/{zip,rar,7z*,tar,gzip,xz,zstd,bzip*,lzma,compress,archive,cpio,arj,xar,ms-cab*}", run = "archive" },
{ mime = "application/{debian*-package,redhat-package-manager,rpm,android.package-archive}", run = "archive" },
{ name = "*.{AppImage,appimage}", run = "archive" },
# Virtual Disk / Disk Image
{ mime = "application/{iso9660-image,qemu-disk,ms-wim,apple-diskimage}", run = "archive" },
{ mime = "application/virtualbox-{vhd,vhdx}", run = "archive" },
{ name = "*.{img,fat,ext,ext2,ext3,ext4,squashfs,ntfs,hfs,hfsx}", run = "archive" },
# Font
{ mime = "font/*", run = "font" },
{ mime = "application/ms-opentype", run = "font" },
# Empty file
{ mime = "inode/empty", run = "empty" },
# Fallback
{ name = "*", run = "file" },
]
[input]
cursor_blink = false
# cd
cd_title = "Change directory:"
cd_origin = "top-center"
cd_offset = [ 0, 2, 50, 3 ]
# create
create_title = [ "Create:", "Create (dir):" ]
create_origin = "top-center"
create_offset = [ 0, 2, 50, 3 ]
# rename
rename_title = "Rename:"
rename_origin = "hovered"
rename_offset = [ 0, 1, 50, 3 ]
# filter
filter_title = "Filter:"
filter_origin = "top-center"
filter_offset = [ 0, 2, 50, 3 ]
# find
find_title = [ "Find next:", "Find previous:" ]
find_origin = "top-center"
find_offset = [ 0, 2, 50, 3 ]
# search
search_title = "Search via {n}:"
search_origin = "top-center"
search_offset = [ 0, 2, 50, 3 ]
# shell
shell_title = [ "Shell:", "Shell (block):" ]
shell_origin = "top-center"
shell_offset = [ 0, 2, 50, 3 ]
[confirm]
# trash
trash_title = "Trash {n} selected file{s}?"
trash_origin = "center"
trash_offset = [ 0, 0, 70, 20 ]
# delete
delete_title = "Permanently delete {n} selected file{s}?"
delete_origin = "center"
delete_offset = [ 0, 0, 70, 20 ]
# overwrite
overwrite_title = "Overwrite file?"
overwrite_content = "Will overwrite the following file:"
overwrite_origin = "center"
overwrite_offset = [ 0, 0, 50, 15 ]
# quit
quit_title = "Quit?"
quit_content = "The following tasks are still running, are you sure you want to quit?"
quit_origin = "center"
quit_offset = [ 0, 0, 50, 15 ]
[pick]
open_title = "Open with:"
open_origin = "hovered"
open_offset = [ 0, 1, 50, 7 ]
[which]
sort_by = "none"
sort_sensitive = false
sort_reverse = false
sort_translit = false