Compare commits
No commits in common. "f65f5426b5894a73d9fcefa8fc542e57c0bd21fc" and "7ced789708b71f8def5dcb6a300ea62baf46c5f0" have entirely different histories.
f65f5426b5
...
7ced789708
5 changed files with 77 additions and 55 deletions
|
|
@ -2,7 +2,13 @@
|
||||||
### MONITORS ###
|
### MONITORS ###
|
||||||
################
|
################
|
||||||
|
|
||||||
monitor=DP-2,3840x2160@160,0x0,1.5
|
{{- if eq .chezmoi.hostname "wkz-pc" }}
|
||||||
|
monitor = DP-2, 3840x2160@160, 0x0, 1.5, bitdepth,10
|
||||||
|
{{- else if eq .chezmoi.hostname "lapdog" }}
|
||||||
|
monitor = eDP-1, 1920x1080@60, 0x0, 1.33
|
||||||
|
{{- else }}
|
||||||
|
monitor = , preferred, auto, 1
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
xwayland {
|
xwayland {
|
||||||
force_zero_scaling = true
|
force_zero_scaling = true
|
||||||
|
|
@ -31,6 +37,9 @@ exec-once = uwsm app -- hyprpaper
|
||||||
exec-once = uwsm app -- hyprsunset
|
exec-once = uwsm app -- hyprsunset
|
||||||
exec-once = [workspace 1] $terminal
|
exec-once = [workspace 1] $terminal
|
||||||
exec-once = [workspace 2 silent] $browser
|
exec-once = [workspace 2 silent] $browser
|
||||||
|
{{- if eq .chezmoi.hostname "lapdog" }}
|
||||||
|
exec-once = uwsm app -- iio-hyprland
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
#############################
|
#############################
|
||||||
### ENVIRONMENT VARIABLES ###
|
### ENVIRONMENT VARIABLES ###
|
||||||
|
|
@ -150,7 +159,11 @@ input {
|
||||||
kb_layout = ee
|
kb_layout = ee
|
||||||
kb_variant =
|
kb_variant =
|
||||||
kb_model =
|
kb_model =
|
||||||
|
{{- if eq .chezmoi.hostname "lapdog" }}
|
||||||
|
kb_options = caps:swapescape, fkeys:basic_13-24
|
||||||
|
{{- else }}
|
||||||
kb_options = fkeys:basic_13-24
|
kb_options = fkeys:basic_13-24
|
||||||
|
{{- end }}
|
||||||
kb_rules =
|
kb_rules =
|
||||||
|
|
||||||
follow_mouse = 1
|
follow_mouse = 1
|
||||||
|
|
@ -40,18 +40,24 @@ return {
|
||||||
event = "VeryLazy"
|
event = "VeryLazy"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"williamboman/mason-lspconfig.nvim",
|
"mason-org/mason-lspconfig.nvim",
|
||||||
dependencies = {
|
dependencies = {
|
||||||
"williamboman/mason.nvim",
|
{
|
||||||
|
"mason-org/mason.nvim",
|
||||||
|
opts = {
|
||||||
|
ensure_installed = {
|
||||||
|
"shfmt",
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
"neovim/nvim-lspconfig",
|
"neovim/nvim-lspconfig",
|
||||||
"saghen/blink.cmp"
|
"saghen/blink.cmp"
|
||||||
},
|
},
|
||||||
event = { "BufReadPre", "BufNewFile" },
|
event = { "BufReadPre", "BufNewFile" },
|
||||||
config = function()
|
config = function()
|
||||||
require("mason").setup()
|
|
||||||
require("mason-lspconfig").setup({
|
require("mason-lspconfig").setup({
|
||||||
automatic_installation = true,
|
automatic_installation = true,
|
||||||
ensure_installed = { "lua_ls", "clangd", "rust_analyzer", "pyright", "marksman", "tailwindcss" }
|
ensure_installed = { "lua_ls", "bashls", "clangd", "rust_analyzer", "pyright", "marksman", "tailwindcss" }
|
||||||
})
|
})
|
||||||
local blinkCapabilities = require("blink.cmp").get_lsp_capabilities()
|
local blinkCapabilities = require("blink.cmp").get_lsp_capabilities()
|
||||||
vim.lsp.config("lua_ls", {
|
vim.lsp.config("lua_ls", {
|
||||||
|
|
@ -70,6 +76,15 @@ return {
|
||||||
},
|
},
|
||||||
capabilities = blinkCapabilities
|
capabilities = blinkCapabilities
|
||||||
})
|
})
|
||||||
|
vim.lsp.config("bashls", {
|
||||||
|
filetypes = { "bash", "sh", "zsh" },
|
||||||
|
settings = {
|
||||||
|
bashIde = {
|
||||||
|
globPattern = "*@(.sh|.inc|.bash|.command|.zsh)"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
capabilities = blinkCapabilities
|
||||||
|
})
|
||||||
vim.lsp.config("clangd", { capabilities = blinkCapabilities })
|
vim.lsp.config("clangd", { capabilities = blinkCapabilities })
|
||||||
vim.lsp.config("rust_analyzer", { capabilities = blinkCapabilities })
|
vim.lsp.config("rust_analyzer", { capabilities = blinkCapabilities })
|
||||||
vim.lsp.config("pyright", { capabilities = blinkCapabilities })
|
vim.lsp.config("pyright", { capabilities = blinkCapabilities })
|
||||||
|
|
@ -88,6 +103,7 @@ return {
|
||||||
require("conform").setup({
|
require("conform").setup({
|
||||||
formatters_by_ft = {
|
formatters_by_ft = {
|
||||||
nix = { "nixfmt" },
|
nix = { "nixfmt" },
|
||||||
|
zsh = { "shfmt" },
|
||||||
-- TODO: More formatters by filetype
|
-- TODO: More formatters by filetype
|
||||||
},
|
},
|
||||||
format_on_save = function(bufnr)
|
format_on_save = function(bufnr)
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,9 @@
|
||||||
source <(fzf --zsh)
|
source <(fzf --zsh)
|
||||||
source <(rip completions zsh | sed "s/'::targets/':targets/")
|
source <(rip completions zsh)
|
||||||
source <(rbw gen-completions zsh)
|
source <(rbw gen-completions zsh)
|
||||||
eval "$(zoxide init zsh)"
|
eval "$(zoxide init zsh)"
|
||||||
|
|
||||||
function load-completions {
|
function qmk-completions {
|
||||||
source $QMK_LOCATION/util/qmk_tab_complete.sh
|
autoload -Uz bashcompinit && bashcompinit
|
||||||
|
source "$(qmk env | grep QMK_HOME | cut -f2 -d '"')"/util/qmk_tab_complete.sh
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,9 +5,9 @@ zshcache_time="$(date +%s%N)"
|
||||||
autoload -Uz add-zsh-hook
|
autoload -Uz add-zsh-hook
|
||||||
|
|
||||||
rehash_precmd() {
|
rehash_precmd() {
|
||||||
if [[ -a /var/cache/zsh/pacman ]]; then
|
if [[ -e /var/cache/zsh/pacman ]]; then
|
||||||
local paccache_time="$(date -r /var/cache/zsh/pacman +%s%N)"
|
local paccache_time="$(date -r /var/cache/zsh/pacman +%s%N)"
|
||||||
if (( zshcache_time < paccache_time )); then
|
if ((zshcache_time < paccache_time)); then
|
||||||
rehash
|
rehash
|
||||||
zshcache_time="$paccache_time"
|
zshcache_time="$paccache_time"
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
if [ -n "${ZSH_DEBUG_STARTUP+1}" ]; then
|
if [[ -n "${ZSH_DEBUG_STARTUP+1}" ]]; then
|
||||||
zmodload zsh/zprof
|
zmodload zsh/zprof
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
@ -10,48 +10,39 @@ setopt INC_APPEND_HISTORY
|
||||||
export EDITOR=nvim
|
export EDITOR=nvim
|
||||||
export MANPAGER='nvim +Man!'
|
export MANPAGER='nvim +Man!'
|
||||||
|
|
||||||
PROMPT="
|
setopt PROMPT_SUBST
|
||||||
[%n@%m %~]%(?..%F{red})>%f "
|
PROMPT=$'\n%n@%m %~%(?..%F{red}) %%%f '
|
||||||
|
|
||||||
zstyle :compinstall filename '/home/wekuz/.zshrc'
|
zstyle :compinstall filename '$HOME/.zshrc'
|
||||||
zstyle ':completion:*' matcher-list 'm:{a-zA-Z}={A-Za-z}'
|
zstyle ':completion:*' matcher-list 'm:{a-zA-Z}={A-Za-z}'
|
||||||
zstyle ':completion:*' menu select
|
zstyle ':completion:*' menu select
|
||||||
autoload -Uz compinit
|
autoload -Uz compinit
|
||||||
compinit
|
if [[ ! -f ~/.zcompdump || -f ~/.zcompdump(N.mh+24) ]]; then
|
||||||
autoload -Uz bashcompinit
|
compinit
|
||||||
bashcompinit
|
else
|
||||||
|
compinit -C
|
||||||
export PATH="$PATH:/home/wekuz/.local/bin"
|
fi
|
||||||
|
export PATH="$PATH:$HOME/.local/bin"
|
||||||
export PATH="$PATH:$HOME/.cargo/bin"
|
export PATH="$PATH:$HOME/.cargo/bin"
|
||||||
|
|
||||||
QMK_LOCATION="/home/wekuz/qmk"
|
for file in "$XDG_CONFIG_HOME"/zsh/config/*.zsh(N); do
|
||||||
|
[ -r "$file" ] && source "$file"
|
||||||
ZSH_CONFIG_FILES=(
|
|
||||||
fixkeys
|
|
||||||
options
|
|
||||||
aliases
|
|
||||||
completions
|
|
||||||
autostart
|
|
||||||
)
|
|
||||||
|
|
||||||
for filename in "${ZSH_CONFIG_FILES[@]}"; do
|
|
||||||
[ -r "$XDG_CONFIG_HOME/zsh/config/$filename.zsh" ] && source "$XDG_CONFIG_HOME/zsh/config/$filename.zsh"
|
|
||||||
done
|
done
|
||||||
|
|
||||||
function plugin-compile {
|
function plugin-compile {
|
||||||
ZPLUGINDIR=${ZPLUGINDIR:-$HOME/.config/zsh/plugins}
|
ZPLUGINDIR=${ZPLUGINDIR:-"$XDG_CONFIG_HOME"/zsh/plugins}
|
||||||
autoload -U zrecompile
|
autoload -U zrecompile
|
||||||
local f
|
local f
|
||||||
for f in $ZPLUGINDIR/**/*.zsh{,-theme}(N); do
|
for f in "$ZPLUGINDIR"/**/*.zsh{,-theme}(N); do
|
||||||
zrecompile -pq "$f"
|
zrecompile -pq "$f"
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
function plugin-clone {
|
function plugin-clone {
|
||||||
|
ZPLUGINDIR=${ZPLUGINDIR:-"$XDG_CONFIG_HOME"/zsh/plugins}
|
||||||
local repo plugdir initfile initfiles=()
|
local repo plugdir initfile initfiles=()
|
||||||
ZPLUGINDIR=${ZPLUGINDIR:-${ZDOTDIR:-$HOME/.config/zsh}/plugins}
|
for repo in "$@"; do
|
||||||
for repo in $@; do
|
plugdir="$ZPLUGINDIR"/${repo:t}
|
||||||
plugdir=$ZPLUGINDIR/${repo:t}
|
|
||||||
initfile=$plugdir/${repo:t}.plugin.zsh
|
initfile=$plugdir/${repo:t}.plugin.zsh
|
||||||
if [[ ! -d $plugdir ]]; then
|
if [[ ! -d $plugdir ]]; then
|
||||||
echo "Cloning $repo..."
|
echo "Cloning $repo..."
|
||||||
|
|
@ -60,7 +51,7 @@ function plugin-clone {
|
||||||
fi
|
fi
|
||||||
if [[ ! -e $initfile ]]; then
|
if [[ ! -e $initfile ]]; then
|
||||||
initfiles=($plugdir/*.{plugin.zsh,zsh-theme,zsh,sh}(N))
|
initfiles=($plugdir/*.{plugin.zsh,zsh-theme,zsh,sh}(N))
|
||||||
(( $#initfiles )) && ln -sf $initfiles[1] $initfile
|
(($#initfiles)) && ln -sf $initfiles[1] $initfile
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
plugin-compile
|
plugin-compile
|
||||||
|
|
@ -68,18 +59,19 @@ function plugin-clone {
|
||||||
|
|
||||||
function plugin-source {
|
function plugin-source {
|
||||||
local plugdir
|
local plugdir
|
||||||
ZPLUGINDIR=${ZPLUGINDIR:-${ZDOTDIR:-$HOME/.config/zsh}/plugins}
|
ZPLUGINDIR=${ZPLUGINDIR:-"$XDG_CONFIG_HOME"/zsh/plugins}
|
||||||
for plugdir in $@; do
|
for plugdir in "$@"; do
|
||||||
[[ $plugdir = /* ]] || plugdir=$ZPLUGINDIR/$plugdir
|
[[ $plugdir = /* ]] || plugdir="$ZPLUGINDIR"/$plugdir
|
||||||
fpath+=$plugdir
|
fpath+=$plugdir
|
||||||
local initfile=$plugdir/${plugdir:t}.plugin.zsh
|
local initfile=$plugdir/${plugdir:t}.plugin.zsh
|
||||||
(( $+functions[zsh-defer] )) && zsh-defer . $initfile || . $initfile
|
(($+functions[zsh-defer])) && zsh-defer . $initfile || . $initfile
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
function plugin-update {
|
function plugin-update {
|
||||||
ZPLUGINDIR=${ZPLUGINDIR:-$HOME/.config/zsh/plugins}
|
ZPLUGINDIR=${ZPLUGINDIR:-"$XDG_CONFIG_HOME"/zsh/plugins}
|
||||||
for d in $ZPLUGINDIR/*/.git(/); do
|
local d
|
||||||
|
for d in "$ZPLUGINDIR"/*/.git(/); do
|
||||||
echo "Updating ${d:h:t}..."
|
echo "Updating ${d:h:t}..."
|
||||||
command git -C "${d:h}" pull --ff --recurse-submodules --depth 1 --rebase --autostash
|
command git -C "${d:h}" pull --ff --recurse-submodules --depth 1 --rebase --autostash
|
||||||
done
|
done
|
||||||
|
|
@ -89,17 +81,17 @@ function plugin-update {
|
||||||
|
|
||||||
ZSH_PLUGIN_REPOS=(
|
ZSH_PLUGIN_REPOS=(
|
||||||
hlissner/zsh-autopair
|
hlissner/zsh-autopair
|
||||||
zsh-users/zsh-syntax-highlighting
|
|
||||||
zsh-users/zsh-autosuggestions
|
zsh-users/zsh-autosuggestions
|
||||||
)
|
zsh-users/zsh-syntax-highlighting # https://github.com/zsh-users/zsh-syntax-highlighting#why-must-zsh-syntax-highlightingzsh-be-sourced-at-the-end-of-the-zshrc-file
|
||||||
ZSH_PLUGINS=(
|
|
||||||
zsh-autopair
|
|
||||||
zsh-syntax-highlighting
|
|
||||||
zsh-autosuggestions
|
|
||||||
)
|
)
|
||||||
|
|
||||||
# plugin-clone $ZSH_PLUGIN_REPOS
|
# Plugin bootstrap
|
||||||
plugin-source $ZSH_PLUGINS
|
if [[ ! -d ${ZPLUGINDIR:-"$XDG_CONFIG_HOME"/zsh/plugins} ]]; then
|
||||||
|
echo "Bootstraping plugins..."
|
||||||
|
plugin-clone "${ZSH_PLUGIN_REPOS[@]}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
plugin-source "${(@)ZSH_PLUGIN_REPOS:t}"
|
||||||
|
|
||||||
if [ -n "${ZSH_DEBUG_STARTUP+1}" ]; then
|
if [ -n "${ZSH_DEBUG_STARTUP+1}" ]; then
|
||||||
zprof
|
zprof
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue