Updated config

This commit is contained in:
Eduard Urbach 2024-03-05 13:28:48 +01:00
parent 307d253d9e
commit eca02857ec
Signed by: akyoto
GPG Key ID: C874F672B1AF20C0
11 changed files with 150 additions and 78 deletions

View File

@ -33,6 +33,7 @@ alias pu "sudo pacman -Syu"
alias pl "pacman -Q"
alias po "pacman -Qo"
alias pc "sudo pacman -Sc"
alias paur "pacman -Qm"
alias porphan "pacman -Qtdq"
# Tmux

View File

@ -5,7 +5,7 @@ SETUVAR fish_color_autosuggestion:707A8C
SETUVAR fish_color_cancel:\x2d\x2dreverse
SETUVAR fish_color_command:00ff00
SETUVAR fish_color_comment:5C6773
SETUVAR fish_color_cwd:73D0FF
SETUVAR fish_color_cwd:66D9EF
SETUVAR fish_color_cwd_root:red
SETUVAR fish_color_end:F29E74
SETUVAR fish_color_error:FF3333

View File

@ -0,0 +1,12 @@
animations {
enabled = yes
bezier = myBezier, 0.05, 0.9, 0.1, 1.05
animation = windows, 1, 2, myBezier
animation = windowsOut, 1, 2, default, popin 80%
animation = border, 1, 5, default
animation = borderangle, 1, 3, default
animation = fade, 1, 2, default
animation = workspaces, 1, 1, default
}

View File

@ -1,8 +1,3 @@
# https://github.com/hyprwm/Hyprland/issues/2591
$XDG_DATA_HOME=$HOME/.local/share
$XDG_CONFIG_HOME=$HOME/.config
$XDG_STATE_HOME=$HOME/.local/state
$XDG_CACHE_HOME=$HOME/.cache
# Firefox
env = MOZ_ENABLE_WAYLAND,1
@ -32,6 +27,17 @@ env = GDK_BACKEND,wayland
env = WLR_NO_HARDWARE_CURSORS,1
env = WLR_RENDERER,vulkan
# https://github.com/hyprwm/Hyprland/issues/2591
$XDG_DATA_HOME=$HOME/.local/share
$XDG_CONFIG_HOME=$HOME/.config
$XDG_STATE_HOME=$HOME/.local/state
$XDG_CACHE_HOME=$HOME/.cache
env = XDG_DATA_HOME,$XDG_DATA_HOME
env = XDG_CONFIG_HOME,$XDG_CONFIG_HOME
env = XDG_STATE_HOME,$XDG_STATE_HOME
env = XDG_CACHE_HOME,$XDG_CACHE_HOME
# Config directories
env = HISTFILE,$XDG_STATE_HOME/bash/history
env = CARGO_HOME,$XDG_DATA_HOME/cargo

View File

@ -1,8 +1,9 @@
general {
gaps_in = 5
gaps_out = 10
gaps_in = 4
gaps_out = 6
border_size = 0
border_size = 2
col.active_border = rgba(33ccffee) rgba(00ff99ee) 45deg
col.inactive_border = rgba(595959aa)
@ -24,35 +25,29 @@ input {
natural_scroll = no
}
sensitivity = 0 # -1.0 - 1.0, 0 means no modification.
sensitivity = 0
accel_profile = flat
}
decoration {
rounding = 3
rounding = 10
blur {
enabled = true
size = 3
passes = 1
size = 4
passes = 4
new_optimizations = on
ignore_opacity = on
xray = false
}
drop_shadow = yes
shadow_range = 4
shadow_render_power = 3
col.shadow = rgba(1a1a1aee)
}
animations {
enabled = yes
bezier = myBezier, 0.05, 0.9, 0.1, 1.05
animation = windows, 1, 2, myBezier
animation = windowsOut, 1, 2, default, popin 80%
animation = border, 1, 5, default
animation = borderangle, 1, 3, default
animation = fade, 1, 2, default
animation = workspaces, 1, 1, default
#active_opacity = 1.0
#inactive_opacity = 0.75
}
dwindle {

View File

@ -3,5 +3,6 @@ source = programs.conf
source = environment.conf
source = autostart.conf
source = general.conf
source = animations.conf
source = rules.conf
source = keys.conf

View File

@ -33,8 +33,9 @@ on({ "VimEnter" }, {
callback = function()
-- Change file to its directory if needed
local name = vim.api.nvim_buf_get_name(0)
local is_directory = vim.fn.isdirectory(name)
if vim.fn.isdirectory(name) == 0 then
if is_directory == 0 then
name = vim.fs.dirname(name)
end
@ -50,18 +51,22 @@ on({ "VimEnter" }, {
else
vim.api.nvim_set_current_dir(name)
end
end,
})
on({ "VimEnter" }, {
desc = "Open file explorer if there is enough horizontal space",
group = group,
callback = function()
local files = require("nvim-tree.api")
local width = vim.go.columns
if width > 120 then
files.tree.toggle({ focus = false })
if is_directory ~= 0 then
require("telescope.builtin").find_files()
end
end,
})
-- on({ "VimEnter" }, {
-- desc = "Open file explorer if there is enough horizontal space",
-- group = group,
-- callback = function()
-- local files = require("nvim-tree.api")
-- local width = vim.go.columns
--
-- if width > 120 then
-- files.tree.toggle({ focus = false })
-- end
-- end,
-- })

View File

@ -4,13 +4,12 @@ end
-- Basics
map("n", ";", ":", "Command mode")
map("n", "U", "<cmd>redo<cr>", "Redo")
map({ "i", "n" }, "<esc>", "<cmd>noh<cr><esc>", "Clear search")
map({"n", "v"}, "<leader>q", "<cmd>qa!<cr>", "Quit all")
-- Buffer management
map("n", "<C-n>", "<cmd>enew<cr>", "New file")
map({ "i", "n", "s", "v" }, "<C-s>", "<cmd>w<cr><esc>", "Save file")
map({ "i", "n", "s", "v" }, "<C-s>", "<cmd>w<cr>", "Save file")
map("n", "<C-q>", "<cmd>bd<cr>", "Delete buffer")
-- Copy and paste
@ -35,6 +34,10 @@ map("v", "<C-d>", "y/<C-r>\"<cr>N", "Search selection")
map("n", "<C-r>", "*#:%s//<C-r><C-w>/g<left><left>", "Replace word under cursor")
map("v", "<C-r>", "y/<C-r>\"<cr>N:%s//<C-r>\"/g<left><left>", "Replace selection")
-- Editing words
map("n", "<C-w>", "ciw", "Rewrite word")
map("n", "<Bslash>", "<cmd>ToggleWord<cr>", "Toggle word")
-- Indenting
map("n", "<Tab>", "V>gv<esc>")
map("n", "<S-Tab>", "V<gv<esc>")
@ -46,11 +49,13 @@ map("n", "+", "<C-a>", "Increase number")
map("n", "-", "<C-x>", "Decrease number")
map("n", "<kPlus>", "<C-a>", "Increase number")
map("n", "<kMinus>", "<C-x>", "Decrease number")
map("n", "<Bslash>", "<cmd>ToggleWord<cr>", "Toggle word")
-- Package manager
map("n", "<leader>l", "<cmd>Lazy<cr>", "Lazy")
-- Redo
map("n", "U", "<cmd>redo<cr>", "Redo")
-- Shift arrow selection
map("n", "<S-Up>", "v<Up>")
map("n", "<S-Down>", "v<Down>")

View File

@ -0,0 +1,21 @@
{
"layer": "top",
"position": "bottom",
"modules-left": [
"hyprland/workspaces",
"hyprland/window",
],
"modules-center": [],
"modules-right": [
"custom/updates",
"cpu",
"custom/gpu",
"memory",
"disk",
"network#up",
"network#down",
"wireplumber",
"clock",
],
"include": "~/.config/waybar/modules.jsonc",
}

View File

@ -1,12 +1,7 @@
{
"layer": "top",
"position": "bottom",
"modules-left": ["custom/os","hyprland/workspaces"],
"modules-center": ["clock"],
"modules-right": ["cpu","custom/gpu","memory","disk","network","custom/power"],
"clock": {
"interval": 60,
"format": "{:%H : %M}",
"format": "<span color='#ffffff7f'></span> {:%H : %M}",
"tooltip-format": "{:%A, %Y-%m-%d}",
"on-click": "gnome-clocks",
"on-click-right": "date -u +'%Y-%m-%dT%H:%M:%SZ' | wl-copy",
@ -18,12 +13,20 @@
"max-length": 10,
"on-click": "$TERMINAL -e btop",
},
"custom/updates": {
"interval": 300,
"format": "<span color='#ffffff7f'>󰏖 </span> {}",
"exec": "~/.bin/updates",
"return-type": "json",
"on-click": "$TERMINAL -e yay",
},
"custom/gpu": {
"interval": 2,
"exec": "nvidia-smi --query-gpu=utilization.gpu --format=csv,noheader,nounits",
"format": "<span color='#ffffff7f'> </span> {}%",
"return-type": "",
"interval": 2,
"on-click": "$TERMINAL -e nvtop",
"max-length": 10,
},
"memory": {
"interval": 2,
@ -31,28 +34,30 @@
"max-length": 10,
"on-click": "$TERMINAL -e btop",
},
"network": {
"network#up": {
"interval": 2,
"format": " {ifname}",
"format-wifi": " {essid}",
"format-ethernet": "<span color='#ffffff7f'> </span>{bandwidthUpBits} <span color='#ffffff7f'> </span>{bandwidthDownBits}",
"format-disconnected": "",
"tooltip-format": "{ifname} via {gwaddr}",
"tooltip-format-wifi": " {essid} ({signalStrength}%)",
"tooltip-format-ethernet": " {ifname}",
"tooltip-format-disconnected": "",
"max-length": 50,
"format": "<span color='#ffffff7f'> </span>{bandwidthUpBits}",
"tooltip-format": " {ifname} upload",
"max-length": 10,
"on-click": "$TERMINAL -e nethogs",
},
"network#down": {
"interval": 2,
"format": "<span color='#ffffff7f'> </span>{bandwidthDownBits}",
"tooltip-format": " {ifname} download",
"max-length": 10,
"on-click": "$TERMINAL -e nethogs",
},
"disk": {
"interval": 30,
"format": "<span color='#ffffff7f'>󰋊 </span>{used}",
"path": "/",
"max-length": 10,
"on-click": "$TERMINAL -e dua i",
},
"mpris": {
"format": "{player_icon} {title}",
"format-paused": "{status_icon} {title}",
"format": "<span color='#ffffff7f'>{player_icon}</span> {title}",
"format-paused": "<span color='#ffffff7f'>{status_icon}</span> {title}",
"player-icons": {
"default": "󰝚",
"mpv": "󰝚"
@ -66,12 +71,16 @@
"format": "<span color='#ffffff7f'>{icon}</span> {volume}%",
"format-muted": "",
"scroll-step": 5,
"on-click": "helvum",
"format-icons": ["", "", ""],
"max-length": 10,
"on-click": "helvum",
},
"hyprland/window": {
"format": "󰘔 {initialTitle}",
"separate-outputs": true
},
"hyprland/workspaces": {
"format": "{icon}",
"on-click": "activate",
"persistent-workspaces": {
"*": 9
},
@ -82,6 +91,7 @@
"urgent": "",
},
"sort-by-number": true,
"on-click": "activate",
},
"custom/os":{
"format": "",

View File

@ -1,58 +1,74 @@
* {
border: none;
font-family: "Ubuntu Nerd Font";
font-size: 11px;
font-size: 12px;
padding: 0;
margin: 0;
}
window#waybar {
color: #F8F8F2;
background: #272822;
/* border: 2px solid rgba(255, 255, 255, 0.1); */
/* border-radius: 3px; */
/* border-bottom: 1px solid rgba(255, 255, 255, 0.25); */
#waybar {
background: transparent;
}
window#waybar.hidden {
#waybar.hidden {
opacity: 0.2;
}
#waybar #window {
opacity: 1;
transition: opacity 200ms ease;
}
#waybar.empty #window {
opacity: 0;
}
#clock,
#cpu,
#disk,
#memory,
#mpris,
#network,
#window,
#wireplumber,
#workspaces,
#custom-os,
#custom-gpu {
margin: 0 8px;
#custom-gpu,
#custom-updates {
background: rgb(38, 41, 44);
border-radius: 10px;
padding: 4px 8px;
margin: 0px 4px;
margin-bottom: 4px;
}
#workspaces {}
#custom-updates.disabled {
opacity: 0;
}
#workspaces button {
padding: 0px 5px;
color: rgba(255, 255, 255, 0.4);
opacity: 0.8;
background: transparent;
text-shadow: none;
border-radius: 0;
}
#workspaces button.empty {
color: rgba(255, 255, 255, 0.2);
opacity: 0.2;
}
#workspaces button.active {
opacity: 1.0;
}
#workspaces button.visible {}
#workspaces button.urgent {}
#workspaces button.persistent {}
#workspaces button.hidden {}
#workspaces button.active {
color: rgba(255, 255, 255, 1.0);
}
#custom-os {
font-size: 150%;
color: rgb(137, 220, 235);
background: transparent;
}