Massive Updates

This commit is contained in:
sankalp committed 2024-01-09 14:05:16 +05:45
1 parent d9312ecfce
commit 8ec7ccf27a
29 files changed
+462 -193

No files matched your search

@@ -11,6 +11,8 @@ $scriptsDir = $HOME/.config/hypr/scripts
$UserScripts = $HOME/.config/hypr/UserScripts
bindr = ALT, ALT_L, exec, pkill rofi || $UserScripts/Xmenu.sh
# rofi App launcher
bindr = $mainMod, $mainMod_L, exec, pkill rofi || rofi -show drun -modi drun,filebrowser,run,window -config ~/.config/rofi/launcher.rasi
bind = $mainMod, D, exec, pkill rofi || rofi -show drun -modi drun,filebrowser,run,window -config ~/.config/rofi/launcher.rasi
+2 -2
View File
@@ -8,8 +8,8 @@ notif="$HOME/.config/swaync/images/bell.png"
HYPRLAND_DEVICE="dll07a7:01-044e:120b"
XDG_RUNTIME_DIR=${XDG_RUNTIME_DIR:-/run/user/$(id -u)}
STATUS_FILE="$XDG_RUNTIME_DIR/touchpad.status"
DIR=$HOME/.cache
STATUS_FILE="$DIR/touchpad.status"
toggle_touchpad() {
if [ ! -f "$STATUS_FILE" ] || [ "$(cat "$STATUS_FILE")" = "false" ]; then
+95
View File
@@ -0,0 +1,95 @@
#!/bin/bash
# Directory for icons
iDIR="$HOME/.config/swaync/icons"
scriptsDir="$HOME/.config/hypr/scripts"
UserScripts="$HOME/.config/hypr/UserScripts"
yes='Yes'
no='No'
# Note: You can add more options below with the following format:
# ["TITLE"]="link"
# Define menu options as an associative array
declare -A menu_options=(
["nv Neovim"]="kitty -e nvim"
["re RofiEmoji"]="$scriptsDir/RofiEmoji.sh"
["rn RofiNotes"]="$scriptsDir/RofiNotes.sh"
["rs TmuxSesions"]="$scriptsDir/RofiTmuxSesions.sh"
["rt RofiTodo"]="rofi -modi TODO:$scriptsDir/RofiTodo.sh -show TODO"
["ws WallpaperSelect"]="$UserScripts/WallpaperSelect.sh"
["wb ToggleWaybar"]="killall -SIGUSR1 waybar"
["wl WaybarLayout"]="$scriptsDir/WaybarLayout.sh"
["gm GameMode"]="$scriptsDir/ToggleAnimation -t"
["rm RofiMusic"]="$UserScripts/RofiMusic.sh"
["cb ChangeBlur"]="$scriptsDir/ChangeBlur.sh"
["po Shutdown"]="needConfim "poweroff""
["rr Reboot"]="needConfim "reboot""
["pm PowerMenu"]="$scriptsDir/RofiPower.sh"
["rfs Refesh All"]="$scriptsDir/Refresh.sh"
["cc Calculator"]="rofi -modi \"calc:$scriptsDir/RofiCalc.sh\" -show calc"
["fd Finder"]="rofi -modi \"find:$scriptsDir/Finder.sh\" -show find"
["cb Clipborad"]="$scriptsDirt/ClipManager.sh"
["flt Float all window"]="hyprctl dispatch workspaceopt allfloat"
["; Launcher"]="rofi -show drun -modi drun,filebrowser,run,window -config ~/.config/rofi/launcher.rasi"
["ff firefox"]="firefox"
["fp firefox"]="firefox --private-window"
["qe QuickEdit"]="$UserScripts/QuickEdit.sh"
["tp Touchpad"]="$UserScripts/TouchPad.sh"
["yz Yazi"]="kitty -e yazi"
["ds Discord"]="discord"
["tg Telegram"]="telegram-desktop"
["fz FuzzyFind"]="kitty fzf -e"
["tn TermianlNote"]="kitty -e notes"
)
# Function for displaying notifications
notification() {
notify-send -e -u low "$@"
}
confirm_cmd() {
rofi -theme-str 'window {location: center; anchor: center; fullscreen: false; width: 250px;}' \
-theme-str 'mainbox {children: [ "message", "listview" ];}' \
-theme-str 'listview {columns: 2; lines: 1;}' \
-theme-str 'element-text {horizontal-align: 0.5;}' \
-theme-str 'textbox {horizontal-align: 0.5;}' \
-dmenu \
-p 'Confirmation' \
-mesg 'Are you Sure?'
# -theme ${dir}/${theme}.rasi
}
# Ask for confirmation
confirm_exit() {
echo -e "$no\n$yes" | confirm_cmd
}
needConfim() {
selected="$(confirm_exit)"
if [[ "$selected" == "$yes" ]]; then
$1
fi
}
# myt="$(notification number)"
# Main function
main() {
choice=$(
printf "%s\n" "${!menu_options[@]}" |
rofi -dmenu -config ~/.config/rofi/config.rasi \
-p "Rofi" \
-mesg "Hello" \
-max-history-size 0 \
-auto-select
)
if [ -z "$choice" ]; then
exit 1
fi
link="${menu_options[$choice]}"
$link
# notification "$choice"
# test_cmd
}
main
+43
View File
@@ -0,0 +1,43 @@
#!/usr/bin/env bash
if [ ! -z "$@" ]; then
QUERY=$@
# Check if the query starts with "/"
if [[ "$@" == /* ]]; then
if [[ "$@" == *\?\? ]]; then
# If the query ends with "??", open the directory
coproc ( exo-open "${QUERY%\/* \?\?}" > /dev/null 2>&1 )
exec 1>&-
exit;
else
# Open the file or directory
coproc ( exo-open "$@" > /dev/null 2>&1 )
exec 1>&-
exit;
fi
elif [[ "$@" == \!\!* ]]; then
# Display help messages
echo "!!-- Type your search query to find files"
echo "!!-- To search again type !<search_query>"
echo "!!-- To search parent directories type ?<search_query>"
echo "!!-- You can print this help by typing !!"
elif [[ "$@" == \?* ]]; then
# Display search results for parent directories, including hidden files
echo "!!-- Type another search query"
while read -r line; do
echo "$line" \?\?
done <<< $(find ~ -type d -o -type f -iname *"${QUERY#\?}"* -print)
else
# Display search results for files, including hidden files
echo "!!-- Type another search query"
find ~ -type d -o -type f -iname *"${QUERY#!}"* -print
fi
else
# Display initial help messages
echo "!!-- Type your search query to find files"
echo "!!-- To search again type !<search_query>"
echo "!!-- To search parent directories type ?<search_query>"
echo "!!-- You can print this help by typing !!"
fi
+1
View File
@@ -1,6 +1,7 @@
#!/usr/bin/env bash
# A rofi mode script that allows calculations to be done
# by Adnan Shameem (adnan360). License: MIT (Expat)
#
# Usage:
# - Download this into a dir
-64
View File
@@ -1,64 +0,0 @@
#!/usr/bin/env bash
# Requirements:
# rofi
# Description:
# Use rofi to search the web.
# Usage:
# web-search.sh
# -----------------------------------------------------------------------------
# Script:
declare -A URLS
URLS=(
["google"]="https://www.google.com/search?q="
["bing"]="https://www.bing.com/search?q="
["yahoo"]="https://search.yahoo.com/search?p="
["duckduckgo"]="https://www.duckduckgo.com/?q="
["yandex"]="https://yandex.ru/yandsearch?text="
["github"]="https://github.com/search?q="
["goodreads"]="https://www.goodreads.com/search?q="
["stackoverflow"]="http://stackoverflow.com/search?q="
["symbolhound"]="http://symbolhound.com/?q="
["searchcode"]="https://searchcode.com/?q="
["openhub"]="https://www.openhub.net/p?ref=homepage&query="
["superuser"]="http://superuser.com/search?q="
["askubuntu"]="http://askubuntu.com/search?q="
["imdb"]="http://www.imdb.com/find?ref_=nv_sr_fn&q="
["rottentomatoes"]="https://www.rottentomatoes.com/search/?search="
["piratebay"]="https://thepiratebay.org/search/"
["youtube"]="https://www.youtube.com/results?search_query="
["vimawesome"]="http://vimawesome.com/?q="
)
# List for rofi
gen_list() {
for i in "${!URLS[@]}"
do
echo "$i"
done
}
main() {
# Pass the list to rofi
platform=$( (gen_list) | rofi -dmenu -matching fuzzy -no-custom -location 0 -p "Search > " )
if [[ -n "$platform" ]]; then
query=$( (echo ) | rofi -dmenu -matching fuzzy -location 0 -p "Query > " )
if [[ -n "$query" ]]; then
url=${URLS[$platform]}$query
xdg-open "$url"
else
exit
fi
else
exit
fi
}
main
exit 0
+7 -1
View File
@@ -1,4 +1,3 @@
# :herb: ‎ <samp>About</samp>
<!--toc:start-->
@@ -391,6 +390,7 @@
- [folke/edgy.nvim](https://dotfyle.com/plugins/folke/edgy.nvim)
- [anuvyklack/windows.nvim](https://dotfyle.com/plugins/anuvyklack/windows.nvim)
- [mrjones2014/smart-splits.nvim](https://dotfyle.com/plugins/mrjones2014/smart-splits.nvim)
- [aserowy/tmux.nvim](https://dotfyle.com/plugins/aserowy/tmux.nvim)
- [sindrets/winshift.nvim](https://dotfyle.com/plugins/sindrets/winshift.nvim)
- [echasnovski/mini.bufremove](https://dotfyle.com/plugins/echasnovski/mini.bufremove)
@@ -567,18 +567,22 @@
- biome
- cmakelint
- credo
- cspell
- eslint
- fish
- golangcil-lint
- hadolint
- markdownlint
- pylint
- shellcheck
- stylelint
- terraform_validate
- typos
- vale
### Formatters
- biome
- black
- csharpier
- fish_indent
@@ -591,6 +595,8 @@
- shfmt
- stylua
- terraform_fmt
- trim_newlines
- trim_whitespace
# :gear: ‎ <samp>Config</samp>
+1
View File
@@ -0,0 +1 @@
vim.opt.conceallevel = 0
+1
View File
@@ -0,0 +1 @@
vim.opt.conceallevel = 0
+2
View File
@@ -0,0 +1,2 @@
vim.keymap.set({ "n", "x" }, "<C-j>", [[/^#\+ .*<CR>]], { desc = "Next Heading", buffer = true })
vim.keymap.set({ "n", "x" }, "<C-k>", [[?^#\+ .*<CR>]], { desc = "Prev Heading", buffer = true })
+15 -15
View File
@@ -1,7 +1,7 @@
{
"LazyVim": { "branch": "main", "commit": "879e29504d43e9f178d967ecc34d482f902e5a91" },
"LuaSnip": { "branch": "master", "commit": "2f0db89fcb22d27b908b3609d2441c02798106ab" },
"SchemaStore.nvim": { "branch": "main", "commit": "7ccffe69a8c24fcd8637788955e13d7fd8aa2f46" },
"LuaSnip": { "branch": "master", "commit": "82108e7e31cc6fc223cc5df5cae6d89f70bb199f" },
"SchemaStore.nvim": { "branch": "main", "commit": "958d16c554a4a7dba8332707cded68f791b75d89" },
"actions-preview.nvim": { "branch": "master", "commit": "dd63df1a4ed0ffe1458945ee50ecb1dd02b605ab" },
"animation.nvim": { "branch": "main", "commit": "fb77091ab72ec9971aee0562e7081182527aaa6a" },
"autolist.nvim": { "branch": "main", "commit": "5f70a5f99e96c8fe3069de042abd2a8ed2deb855" },
@@ -15,7 +15,7 @@
"cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" },
"cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" },
"codeium.vim": { "branch": "main", "commit": "4063291e335e74e9ee2be04beb47d40b376312fa" },
"comment-box.nvim": { "branch": "main", "commit": "9dbd4b0a7731d2de20daf646a385177a82f98247" },
"comment-box.nvim": { "branch": "main", "commit": "80857fa3ec01f9d43431cbc4042f9a5ebd9a8811" },
"compiler.nvim": { "branch": "main", "commit": "e7a8b34e8a48d57d50882ada13ab409a00d20471" },
"conform.nvim": { "branch": "master", "commit": "0e61fc88f725b4411e63b43470a397c6102534c7" },
"crates.nvim": { "branch": "main", "commit": "6d779c7b85139d89d92a4a0bcf0afbdcf0cd961a" },
@@ -25,10 +25,10 @@
"diffview.nvim": { "branch": "main", "commit": "3dc498c9777fe79156f3d32dddd483b8b3dbd95f" },
"dooku.nvim": { "branch": "main", "commit": "10d7ccca5cdd30d4d03bc7433023590ca620edc7" },
"dressing.nvim": { "branch": "master", "commit": "94b0d24483d56f3777ee0c8dc51675f21709318c" },
"dropbar.nvim": { "branch": "master", "commit": "0fcb0c7c6592ca4f3f01afd32c62d2e733037822" },
"dropbar.nvim": { "branch": "master", "commit": "bfba257774f78de384cca898d88cc1bb14c5a228" },
"edgy.nvim": { "branch": "main", "commit": "8355be45610afdf79a0bab32b91ee297997455b4" },
"flash.nvim": { "branch": "main", "commit": "48817af25f51c0590653bbc290866e4890fe1cbe" },
"friendly-snippets": { "branch": "main", "commit": "53d3df271d031c405255e99410628c26a8f0d2b0" },
"friendly-snippets": { "branch": "main", "commit": "69a2c1675b66e002799f5eef803b87a12f593049" },
"garbage-day.nvim": { "branch": "main", "commit": "957499b8a493974bd7002b68b1f15f7d285e0dd1" },
"git-worktree.nvim": { "branch": "master", "commit": "f247308e68dab9f1133759b05d944569ad054546" },
"gitsigns.nvim": { "branch": "main", "commit": "3e6e91b09f0468c32d3b96dcacf4b947f037ce25" },
@@ -79,47 +79,47 @@
"nvim-dap-virtual-text": { "branch": "master", "commit": "d4542ac257d3c7ee4131350db6179ae6340ce40b" },
"nvim-devdocs": { "branch": "master", "commit": "521d24661ffe6d1ba025debea2675c765a9c1ee1" },
"nvim-lightbulb": { "branch": "master", "commit": "8f00b89dd1b1dbde16872bee5fbcee2e58c9b8e9" },
"nvim-lint": { "branch": "master", "commit": "d44185d3e57e00c164485a454174294b36ef7067" },
"nvim-lint": { "branch": "master", "commit": "8df53b5dde8ea80f0a039775777eae6648a10229" },
"nvim-lsp-file-operations": { "branch": "master", "commit": "8e7223e138590c1bd9d86d3de810e65939d8b12f" },
"nvim-lspconfig": { "branch": "master", "commit": "796394fd19fb878e8dbc4fd1e9c9c186ed07a5f4" },
"nvim-notify": { "branch": "master", "commit": "1576123bff3bed67bc673a3076e591abfe5d8ca9" },
"nvim-numbertoggle": { "branch": "main", "commit": "9ab95e60ea5ec138e1b2332e0fc18b8e5de464c6" },
"nvim-puppeteer": { "branch": "main", "commit": "d7e1b2d67c89d32b6ecada88ff67b539ba09f2d7" },
"nvim-recorder": { "branch": "main", "commit": "daaae505862e816a7efe578e22d6f3d10cd7a2e6" },
"nvim-scissors": { "branch": "main", "commit": "7e3f33ad7495a0d8632a690d35c74e1b38d85ba1" },
"nvim-scissors": { "branch": "main", "commit": "b7f2d6a34b599d97deb5fd9753b4c0c506cfbc2c" },
"nvim-spectre": { "branch": "master", "commit": "d8906855f1949ac97b1e77aaf8d3fe12ed158ddc" },
"nvim-treesitter": { "branch": "master", "commit": "8cd2b230174efbf7b5d9f49fe2f90bda6b5eb16e" },
"nvim-treesitter-context": { "branch": "master", "commit": "652ec514d6ba8bc4a3c2de76c855fe668e2c7196" },
"nvim-treesitter-context": { "branch": "master", "commit": "400a99ad43ac78af1148061da3491cba2637ad29" },
"nvim-treesitter-endwise": { "branch": "master", "commit": "4c344ffc8d54d7e1ba2cefaaa2c10ea93aa1cc2d" },
"nvim-treesitter-textobjects": { "branch": "master", "commit": "85b9d0cbd4ff901abcda862b50dbb34e0901848b" },
"nvim-ts-autotag": { "branch": "main", "commit": "8515e48a277a2f4947d91004d9aa92c29fdc5e18" },
"nvim-ts-context-commentstring": { "branch": "main", "commit": "1277b4a1f451b0f18c0790e1a7f12e1e5fdebfee" },
"nvim-various-textobjs": { "branch": "main", "commit": "ec1b756d20ea78895d89a1fb2903b9e121da4e67" },
"nvim-various-textobjs": { "branch": "main", "commit": "779dd981e55d534a4234d9650c9cbb39e4663c9a" },
"nvim-web-devicons": { "branch": "master", "commit": "db0c864375c198cacc171ff373e76bfce2a85045" },
"nvim_context_vt": { "branch": "master", "commit": "a14f9292b4bd68ceed433fc513f287641816dc6d" },
"octo.nvim": { "branch": "master", "commit": "b5371003f209764c9d1cc43cf20b6dc52961f0e8" },
"openingh.nvim": { "branch": "main", "commit": "5c9e851d7c26fdb236dfea8866b71fefe7ddeffc" },
"outline.nvim": { "branch": "main", "commit": "8c6b11e4c27bca690bfde0c6ce35ba66a805dfa3" },
"overseer.nvim": { "branch": "master", "commit": "d3f9a0205640bda1fb68b5011b427ec4e70f9616" },
"overseer.nvim": { "branch": "master", "commit": "68a2d344cea4a2e11acfb5690dc8ecd1a1ec0ce0" },
"package-info.nvim": { "branch": "master", "commit": "18f8126dd8e65b2e21804c9107785af4abbb5bfc" },
"persistence.nvim": { "branch": "main", "commit": "ad538bfd5336f1335cdb6fd4e0b0eebfa6e12f32" },
"persistent-breakpoints.nvim": { "branch": "main", "commit": "db2ad5974b0435cb806cd287e7525219d6ac4bd3" },
"plenary.nvim": { "branch": "master", "commit": "55d9fe89e33efd26f532ef20223e5f9430c8b0c0" },
"presence.nvim": { "branch": "main", "commit": "87c857a56b7703f976d3a5ef15967d80508df6e6" },
"rainbow-delimiters.nvim": { "branch": "master", "commit": "18d1350ec3897e7282b4cbf78ef6f50191ae78f8" },
"rainbow-delimiters.nvim": { "branch": "master", "commit": "739a034046465d2b100151037401c24c42cb09cf" },
"refactoring.nvim": { "branch": "master", "commit": "28c5a33a0c489eb559396d9424b042ccfdb03b14" },
"rustaceanvim": { "branch": "master", "commit": "f36e3a62b81b9a4ebd1771e6ee81fb5d85383af8" },
"rustaceanvim": { "branch": "master", "commit": "73854d5e720d4ea135e7508d9d24fb82b4ec8223" },
"satellite.nvim": { "branch": "main", "commit": "1a20861227eba8bf2d8282ab4ec5fc071e8b20e2" },
"search-replace.nvim": { "branch": "main", "commit": "d92290a02d97f4e9b8cd60d28b56b403432158d5" },
"semshi": { "branch": "master", "commit": "0182447e2ff4dfa04cd2dfe5f189e012c581ca45" },
"smart-splits.nvim": { "branch": "master", "commit": "403ad1a4fd7eb39388690a5657e7cbfb16da6668" },
"smart-splits.nvim": { "branch": "master", "commit": "2009a38ac44ec7afa1a001e0dfa8358441510a64" },
"sniprun": { "branch": "master", "commit": "551f5839c1ccc8b4d3143ae03f58757d3047e391" },
"sqlite.lua": { "branch": "master", "commit": "b7e28c8463254c46a8e61c52d27d6a2040492fc3" },
"suda.vim": { "branch": "master", "commit": "8b0fc3711760195aba104e2d190cff9af8267052" },
"telescope-all-recent.nvim": { "branch": "main", "commit": "bfd8bb3b9c43bf0d09c2a77f3a5fcbecddbf9908" },
"telescope-floaterm.nvim": { "branch": "main", "commit": "ccd3f40ae30dce5de0e5d0f5069e08e7d9ad6d23" },
"telescope-fzf-native.nvim": { "branch": "main", "commit": "6c921ca12321edaa773e324ef64ea301a1d0da62" },
"telescope-import.nvim": { "branch": "main", "commit": "d735be055a9b773f77089529d3917c0646cf3114" },
"telescope-import.nvim": { "branch": "main", "commit": "08e31708451b43d1ef766d370d5ef17e9f0c24ae" },
"telescope-lazy.nvim": { "branch": "main", "commit": "7a360fc33d0728cf0c18c0032ca36ebfe3cd2a8c" },
"telescope-luasnip.nvim": { "branch": "master", "commit": "2ef7da3a363890686dbaad18ddbf59177cfe4f78" },
"telescope-undo.nvim": { "branch": "main", "commit": "d3afc1c105535a90caec092ce27a113f77ba7b84" },
@@ -129,7 +129,7 @@
"theme-loader.nvim": { "branch": "master", "commit": "ad8774ec8267a447d469b4e6603b43f49b946e53" },
"todo-comments.nvim": { "branch": "main", "commit": "4a6737a8d70fe1ac55c64dfa47fcb189ca431872" },
"tokyonight.nvim": { "branch": "main", "commit": "f247ee700b569ed43f39320413a13ba9b0aef0db" },
"tree-sitter-hyprlang": { "branch": "master", "commit": "9bd008f08ffbfb94146ce9d4f31002de66f0e627" },
"tree-sitter-hyprlang": { "branch": "master", "commit": "43100f854cd5cf4e664a0dab7bf027263ca7cff2" },
"trouble.nvim": { "branch": "main", "commit": "f1168feada93c0154ede4d1fe9183bf69bac54ea" },
"ts-node-action": { "branch": "master", "commit": "e37eb458378de5d994df459a53711b2546abef0f" },
"tsc.nvim": { "branch": "main", "commit": "a8f26d3d6a0faf533afb840816a6d9ac6a1fcbea" },
+5 -3
View File
@@ -35,7 +35,6 @@
"plugins.extras.editor.outline",
"plugins.extras.editor.package-info",
"plugins.extras.editor.search-replace",
"plugins.extras.editor.smart-splits",
"plugins.extras.editor.suda",
"plugins.extras.editor.telescope.all-recent",
"plugins.extras.editor.telescope.import",
@@ -45,7 +44,7 @@
"plugins.extras.editor.telescope.zoxide",
"plugins.extras.editor.terminal.floaterm",
"plugins.extras.formatting.isort",
"plugins.extras.formatting.prettier",
"plugins.extras.formatting.prettier-extended",
"plugins.extras.formatting.rustfmt",
"plugins.extras.formatting.trim_newlines",
"plugins.extras.formatting.trim_whitespace",
@@ -58,6 +57,7 @@
"plugins.extras.lang.sql",
"plugins.extras.lang.web.html-css",
"plugins.extras.lang.web.typescript-extended",
"plugins.extras.linting.biome",
"plugins.extras.linting.cspell",
"plugins.extras.linting.eslint-extended",
"plugins.extras.linting.shellcheck",
@@ -85,6 +85,7 @@
"plugins.extras.util.dot-extended",
"plugins.extras.util.icon-picker",
"plugins.extras.util.kitty-scrollback",
"plugins.extras.util.smart-splits",
"plugins.extras.util.vscode",
"plugins.extras.util.wakatime"
],
@@ -92,4 +93,5 @@
"NEWS.md": "2123"
},
"version": 2
}
}
+2 -80
View File
@@ -11,9 +11,8 @@ local searching_brave = [[:lua vim.fn.system({'xdg-open', 'https://search.brave.
map("n", "<leader>?", searching_brave, { noremap = true, silent = true, desc = "Search current word on brave search" })
-- Toggle background
map("n", "<leader>uB", function()
Util.toggle("background", false, { "light", "dark" })
end, { desc = "Toggle Background" })
-- stylua: ignore
map("n", "<leader>uB", function() Util.toggle("background", false, { "light", "dark" }) end, { desc = "Toggle Background" })
-- Disable lazyterminal keymap
map("n", "<leader>fT", "<Nop>")
@@ -43,8 +42,6 @@ map("n", "<leader>bf", "<cmd>bfirst<cr>", { desc = "First Buffer" })
map("n", "<leader>ba", "<cmd>blast<cr>", { desc = "Last Buffer" })
-- Center the screen automatically
map("n", "<C-d>", "<C-d>zz")
map("n", "<C-u>", "<C-u>zz")
map("n", "n", "nzzzv")
map("n", "N", "Nzzzv")
@@ -106,78 +103,3 @@ map("x", "g/", "<esc>/\\%V", { silent = false, desc = "Search inside visual sele
-- Search visually selected text (slightly better than builtins in Neovim>=0.8)
map("x", "*", [[y/\V<C-R>=escape(@", '/\')<CR><CR>]])
map("x", "#", [[y?\V<C-R>=escape(@", '?\')<CR><CR>]])
if package.loaded["cinnamon"] then
-- DEFAULT_KEYMAPS:
-- Half-window movements:
map({ "n", "x" }, "<C-u>", "<Cmd>lua Scroll('<C-u>', 1, 1)<CR>")
map({ "n", "x" }, "<C-d>", "<Cmd>lua Scroll('<C-d>', 1, 1)<CR>")
-- Page movements:
map({ "n", "x" }, "<C-b>", "<Cmd>lua Scroll('<C-b>', 1, 1)<CR>")
map({ "n", "x" }, "<C-f>", "<Cmd>lua Scroll('<C-f>', 1, 1)<CR>")
map({ "n", "x" }, "<PageUp>", "<Cmd>lua Scroll('<C-b>', 1, 1)<CR>")
map({ "n", "x" }, "<PageDown>", "<Cmd>lua Scroll('<C-f>', 1, 1)<CR>")
-- EXTRA_KEYMAPS:
-- Start/end of file and line number movements:
map({ "n", "x" }, "gg", "<Cmd>lua Scroll('gg')<CR>")
map({ "n", "x" }, "G", "<Cmd>lua Scroll('G', 0, 1)<CR>")
-- Start/end of line:
map({ "n", "x" }, "0", "<Cmd>lua Scroll('0')<CR>")
map({ "n", "x" }, "^", "<Cmd>lua Scroll('^')<CR>")
map({ "n", "x" }, "$", "<Cmd>lua Scroll('$', 0, 1)<CR>")
-- Paragraph movements:
map({ "n", "x" }, "{", "<Cmd>lua Scroll('{')<CR>")
map({ "n", "x" }, "}", "<Cmd>lua Scroll('}')<CR>")
-- Previous/next search result:
map("n", "n", "<Cmd>lua Scroll('n', 1)<CR>")
map("n", "N", "<Cmd>lua Scroll('N', 1)<CR>")
map("n", "*", "<Cmd>lua Scroll('*', 1)<CR>")
map("n", "#", "<Cmd>lua Scroll('#', 1)<CR>")
map("n", "g*", "<Cmd>lua Scroll('g*', 1)<CR>")
map("n", "g#", "<Cmd>lua Scroll('g#', 1)<CR>")
-- Previous/next cursor location:
map("n", "<C-o>", "<Cmd>lua Scroll('<C-o>', 1)<CR>")
map("n", "<C-i>", "<Cmd>lua Scroll('1<C-i>', 1)<CR>")
-- Screen scrolling:
map("n", "zz", "<Cmd>lua Scroll('zz', 0, 1)<CR>")
map("n", "zt", "<Cmd>lua Scroll('zt', 0, 1)<CR>")
map("n", "zb", "<Cmd>lua Scroll('zb', 0, 1)<CR>")
map("n", "z.", "<Cmd>lua Scroll('z.', 0, 1)<CR>")
map("n", "z<CR>", "<Cmd>lua Scroll('zt^', 0, 1)<CR>")
map("n", "z-", "<Cmd>lua Scroll('z-', 0, 1)<CR>")
map("n", "z^", "<Cmd>lua Scroll('z^', 0, 1)<CR>")
map("n", "z+", "<Cmd>lua Scroll('z+', 0, 1)<CR>")
map("n", "<C-y>", "<Cmd>lua Scroll('<C-y>', 0, 1)<CR>")
map("n", "<C-e>", "<Cmd>lua Scroll('<C-e>', 0, 1)<CR>")
-- Horizontal screen scrolling:
map("n", "zH", "<Cmd>lua Scroll('zH')<CR>")
map("n", "zL", "<Cmd>lua Scroll('zL')<CR>")
map("n", "zs", "<Cmd>lua Scroll('zs')<CR>")
map("n", "ze", "<Cmd>lua Scroll('ze')<CR>")
map("n", "zh", "<Cmd>lua Scroll('zh', 0, 1)<CR>")
map("n", "zl", "<Cmd>lua Scroll('zl', 0, 1)<CR>")
-- EXTENDED_KEYMAPS:
-- Up/down movements:
map({ "n", "x" }, "k", "<Cmd>lua Scroll('k', 0, 1)<CR>")
map({ "n", "x" }, "j", "<Cmd>lua Scroll('j', 0, 1)<CR>")
map({ "n", "x" }, "<Up>", "<Cmd>lua Scroll('k', 0, 1)<CR>")
map({ "n", "x" }, "<Down>", "<Cmd>lua Scroll('j', 0, 1)<CR>")
-- Left/right movements:
map({ "n", "x" }, "h", "<Cmd>lua Scroll('h', 0, 1)<CR>")
map({ "n", "x" }, "l", "<Cmd>lua Scroll('l', 0, 1)<CR>")
map({ "n", "x" }, "<Left>", "<Cmd>lua Scroll('h', 0, 1)<CR>")
map({ "n", "x" }, "<Right>", "<Cmd>lua Scroll('l', 0, 1)<CR>")
end
+1
View File
@@ -12,6 +12,7 @@ require("lazy").setup({
-- add LazyVim and import its plugins
{ "LazyVim/LazyVim", import = "lazyvim.plugins" },
{ import = "plugins" },
{ import = "plugins.extras.util.lazyrc" },
},
defaults = {
-- By default, only LazyVim plugins will be lazy-loaded. Your custom plugins will load during startup.
@@ -7,6 +7,8 @@ return {
{ "am", ft = { "markdown", "toml" }, mode = { "o", "x" }, function() require("various-textobjs").mdlink("outer") end, desc = "Markdown Link" },
{ "iC", ft = { "markdown" }, mode = { "o", "x" }, function() require("various-textobjs").mdFencedCodeBlock("inner") end, desc = "CodeBlock" },
{ "aC", ft = { "markdown" }, mode = { "o", "x" }, function() require("various-textobjs").mdFencedCodeBlock("outer") end, desc = "CodeBlock" },
{ "ie", ft = { "markdown" }, mode = { "o", "x" }, function() require("various-textobjs").mdEmphasis("inner") end, desc = "Emphasis" },
{ "ae", ft = { "markdown" }, mode = { "o", "x" }, function() require("various-textobjs").mdEmphasis("outer") end, desc = "Emphasis" },
{ "gd", mode = { "o", "x" }, function() require("various-textobjs").diagnostics() end, desc = "Diagnostics" },
{ "iy", ft = { "python" }, mode = { "o", "x" }, function() require("various-textobjs").pyTripleQuotes("inner") end, desc = "Triple Quotes" },
{ "ay", ft = { "python" }, mode = { "o", "x" }, function() require("various-textobjs").pyTripleQuotes("outer") end, desc = "Triple Quotes" },
@@ -1,19 +0,0 @@
return {
"mrjones2014/smart-splits.nvim",
build = "./kitty/install-kittens.bash",
-- stylua: ignore
keys = {
{ "<C-A-Left>", function() require("smart-splits").resize_left() end, desc = "Resize left", mode = "n" },
{ "<C-A-Down>", function() require("smart-splits").resize_down() end, desc = "Resize down", mode = "n" },
{ "<C-A-Up>", function() require("smart-splits").resize_up() end, desc = "Resize up", mode = "n" },
{ "<C-A-Right>", function() require("smart-splits").resize_right() end, desc = "Resize right", mode = "n" },
{ "<C-h>", function() require("smart-splits").move_cursor_left() end, desc = "Move cursor left", mode = "n" },
{ "<C-j>", function() require("smart-splits").move_cursor_down() end, desc = "Move cursor down", mode = "n" },
{ "<C-k>", function() require("smart-splits").move_cursor_up() end, desc = "Move cursor up", mode = "n" },
{ "<C-l>", function() require("smart-splits").move_cursor_right() end, desc = "Move cursor right", mode = "n" },
{ "<C-A-h>", function() require("smart-splits").swap_buf_left() end, desc = "Swap buffer left", mode = "n" },
{ "<C-A-j>", function() require("smart-splits").swap_buf_down() end, desc = "Swap buffer down", mode = "n" },
{ "<C-A-k>", function() require("smart-splits").swap_buf_up() end, desc = "Swap buffer up", mode = "n" },
{ "<C-A-l>", function() require("smart-splits").swap_buf_right() end, desc = "Swap buffer right", mode = "n" },
},
}
@@ -0,0 +1,60 @@
return {
{
"williamboman/mason.nvim",
opts = function(_, opts)
opts.ensure_installed = opts.ensure_installed or {}
vim.list_extend(opts.ensure_installed, { "biome" })
end,
},
{
"neovim/nvim-lspconfig",
opts = {
servers = {
biome = {
root_dir = require("lspconfig").util.root_pattern("biome.json"),
single_file_support = false,
},
},
},
},
{
"stevearc/conform.nvim",
opts = function(_, opts)
--- Extend the conform plugin config and add given formatters
---@param tbl table<string, conform.FormatterUnit[]> Table of filetype to formatters mappings
local function add_formatters(tbl)
for ft, formatters in pairs(tbl) do
if opts.formatters_by_ft[ft] == nil then
opts.formatters_by_ft[ft] = formatters
else
vim.list_extend(opts.formatters_by_ft[ft], formatters)
end
end
end
add_formatters({
["jsonc"] = { "biome" },
["json"] = { "biome" },
["javascript"] = { "biome" },
["typescript"] = { "biome" },
["typescriptreact"] = { "biome" },
["javascriptreact"] = { "biome" },
})
opts.formatters = {
biome = {
condition = function(self, ctx)
return vim.fs.find({ "biome.json" }, { path = ctx.filename, upward = true })[1]
end,
},
prettier = {
condition = function(self, ctx)
return not vim.fs.find({ "biome.json" }, { path = ctx.filename, upward = true })[1]
end,
},
}
return opts
end,
},
}
@@ -9,8 +9,24 @@ return {
{
"mfussenegger/nvim-lint",
opts = function(_, opts)
opts.linters_by_ft.go = opts.linters_by_ft.go or {}
table.insert(opts.linters_by_ft.go, "golangcilint")
--- Extend the conform plugin config and add given formatters
---@param tbl table<string, conform.FormatterUnit[]> Table of filetype to formatters mappings
local function add_formatters(tbl)
for ft, formatters in pairs(tbl) do
if opts.formatters_by_ft[ft] == nil then
opts.formatters_by_ft[ft] = formatters
else
vim.list_extend(opts.formatters_by_ft[ft], formatters)
end
end
end
add_formatters({
["go"] = { "golangcilint" },
["gomod"] = { "golangcilint" },
["gowork"] = { "golangcilint" },
})
return opts
end,
},
@@ -1,11 +1,88 @@
local map = vim.keymap.set
return {
"declancm/cinnamon.nvim",
event = "VeryLazy",
opts = {
default_keymaps = true,
extra_keymaps = true,
extended_keymaps = true,
override_keymaps = true,
default_delay = 3,
},
config = function()
require("cinnamon").setup({
default_keymaps = true,
extra_keymaps = true,
extended_keymaps = true,
override_keymaps = true,
default_delay = 2,
})
-- DEFAULT_KEYMAPS:
-- Half-window movements:
map({ "n", "x" }, "<C-u>", "<Cmd>lua Scroll('<C-u>', 1, 1)<CR>")
map({ "n", "x" }, "<C-d>", "<Cmd>lua Scroll('<C-d>', 1, 1)<CR>")
-- Page movements:
map({ "n", "x" }, "<C-b>", "<Cmd>lua Scroll('<C-b>', 1, 1)<CR>")
map({ "n", "x" }, "<C-f>", "<Cmd>lua Scroll('<C-f>', 1, 1)<CR>")
map({ "n", "x" }, "<PageUp>", "<Cmd>lua Scroll('<C-b>', 1, 1)<CR>")
map({ "n", "x" }, "<PageDown>", "<Cmd>lua Scroll('<C-f>', 1, 1)<CR>")
-- EXTRA_KEYMAPS:
-- Start/end of file and line number movements:
map({ "n", "x" }, "gg", "<Cmd>lua Scroll('gg')<CR>")
map({ "n", "x" }, "G", "<Cmd>lua Scroll('G', 0, 1)<CR>")
-- Start/end of line:
map({ "n", "x" }, "0", "<Cmd>lua Scroll('0')<CR>")
map({ "n", "x" }, "^", "<Cmd>lua Scroll('^')<CR>")
map({ "n", "x" }, "$", "<Cmd>lua Scroll('$', 0, 1)<CR>")
-- Paragraph movements:
map({ "n", "x" }, "{", "<Cmd>lua Scroll('{')<CR>")
map({ "n", "x" }, "}", "<Cmd>lua Scroll('}')<CR>")
-- Previous/next search result:
map("n", "n", "<Cmd>lua Scroll('n', 1)<CR>")
map("n", "N", "<Cmd>lua Scroll('N', 1)<CR>")
map("n", "*", "<Cmd>lua Scroll('*', 1)<CR>")
map("n", "#", "<Cmd>lua Scroll('#', 1)<CR>")
map("n", "g*", "<Cmd>lua Scroll('g*', 1)<CR>")
map("n", "g#", "<Cmd>lua Scroll('g#', 1)<CR>")
-- Previous/next cursor location:
map("n", "<C-o>", "<Cmd>lua Scroll('<C-o>', 1)<CR>")
map("n", "<C-i>", "<Cmd>lua Scroll('1<C-i>', 1)<CR>")
-- Screen scrolling:
map("n", "zz", "<Cmd>lua Scroll('zz', 0, 1)<CR>")
map("n", "zt", "<Cmd>lua Scroll('zt', 0, 1)<CR>")
map("n", "zb", "<Cmd>lua Scroll('zb', 0, 1)<CR>")
map("n", "z.", "<Cmd>lua Scroll('z.', 0, 1)<CR>")
map("n", "z<CR>", "<Cmd>lua Scroll('zt^', 0, 1)<CR>")
map("n", "z-", "<Cmd>lua Scroll('z-', 0, 1)<CR>")
map("n", "z^", "<Cmd>lua Scroll('z^', 0, 1)<CR>")
map("n", "z+", "<Cmd>lua Scroll('z+', 0, 1)<CR>")
map("n", "<C-y>", "<Cmd>lua Scroll('<C-y>', 0, 1)<CR>")
map("n", "<C-e>", "<Cmd>lua Scroll('<C-e>', 0, 1)<CR>")
-- Horizontal screen scrolling:
map("n", "zH", "<Cmd>lua Scroll('zH')<CR>")
map("n", "zL", "<Cmd>lua Scroll('zL')<CR>")
map("n", "zs", "<Cmd>lua Scroll('zs')<CR>")
map("n", "ze", "<Cmd>lua Scroll('ze')<CR>")
map("n", "zh", "<Cmd>lua Scroll('zh', 0, 1)<CR>")
map("n", "zl", "<Cmd>lua Scroll('zl', 0, 1)<CR>")
-- EXTENDED_KEYMAPS:
-- Up/down movements:
map({ "n", "x" }, "k", "<Cmd>lua Scroll('k', 0, 1)<CR>")
map({ "n", "x" }, "j", "<Cmd>lua Scroll('j', 0, 1)<CR>")
map({ "n", "x" }, "<Up>", "<Cmd>lua Scroll('k', 0, 1)<CR>")
map({ "n", "x" }, "<Down>", "<Cmd>lua Scroll('j', 0, 1)<CR>")
-- Left/right movements:
map({ "n", "x" }, "h", "<Cmd>lua Scroll('h', 0, 1)<CR>")
map({ "n", "x" }, "l", "<Cmd>lua Scroll('l', 0, 1)<CR>")
map({ "n", "x" }, "<Left>", "<Cmd>lua Scroll('h', 0, 1)<CR>")
map({ "n", "x" }, "<Right>", "<Cmd>lua Scroll('l', 0, 1)<CR>")
end,
}
@@ -14,6 +14,7 @@ return {
"markdown",
"python",
"lua",
"html",
},
},
}
@@ -0,0 +1,39 @@
--[[
Enable project-specific plugin specs.
File .lazy.lua:
is read when present in the current working directory
should return a plugin spec
has to be manually trusted for each instance of the file
This extra should be the last plugin spec added to lazy.nvim
See:
:h 'exrc'
:h :trust
--]]
local filepath = vim.fn.fnamemodify(".lazy.lua", ":p")
local file = vim.secure.read(filepath)
if not file then
return {}
end
vim.api.nvim_create_autocmd("User", {
pattern = "VeryLazy",
once = true,
callback = function()
local Config = require("lazy.core.config")
local Util = require("lazyvim.util")
local lazyrc_idx = Util.plugin.extra_idx("lazyrc")
if lazyrc_idx and lazyrc_idx ~= #Config.spec.modules then
Util.warn({
"The `lazyrc` extra must be the last plugin spec added to **lazy.nvim**. ",
"",
"Add `{ import = 'lazyvim.plugins.extras.lazyrc' }` to file `config.lazy`. ",
"Do not use the `LazyExtras` command. ",
}, { title = "LazyVim", once = true })
end
end,
})
return loadstring(file)()
@@ -0,0 +1,19 @@
return {
"mrjones2014/smart-splits.nvim",
build = "./kitty/install-kittens.bash",
-- stylua: ignore
keys = {
{ "<C-A-Left>", function() require("smart-splits").resize_left() end, desc = "Resize left" },
{ "<C-A-Down>", function() require("smart-splits").resize_down() end, desc = "Resize down" },
{ "<C-A-Up>", function() require("smart-splits").resize_up() end, desc = "Resize up" },
{ "<C-A-Right>", function() require("smart-splits").resize_right() end, desc = "Resize right" },
{ "<C-h>", function() require("smart-splits").move_cursor_left() end, desc = "Move cursor left" },
{ "<C-j>", function() require("smart-splits").move_cursor_down() end, desc = "Move cursor down" },
{ "<C-k>", function() require("smart-splits").move_cursor_up() end, desc = "Move cursor up" },
{ "<C-l>", function() require("smart-splits").move_cursor_right() end, desc = "Move cursor right" },
{ "<C-A-h>", function() require("smart-splits").swap_buf_left() end, desc = "Swap buffer left" },
{ "<C-A-j>", function() require("smart-splits").swap_buf_down() end, desc = "Swap buffer down" },
{ "<C-A-k>", function() require("smart-splits").swap_buf_up() end, desc = "Swap buffer up" },
{ "<C-A-l>", function() require("smart-splits").swap_buf_right() end, desc = "Swap buffer right" },
},
}
@@ -0,0 +1,5 @@
return {
"aserowy/tmux.nvim",
event = "VeryLazy",
opts = {},
}
@@ -12,6 +12,10 @@ local map = vim.keymap.set
local enabled = {
"flash.nvim",
"lazy.nvim",
"dial.nvim",
"mini.align",
"comment-box.nvim",
"text-case.nvim",
"mini.ai",
"mini.comment",
"mini.pairs",
@@ -22,6 +26,7 @@ local enabled = {
"nvim-ts-context-commentstring",
"vim-repeat",
"highlight-undo.nvim",
"ts-node-action",
"LazyVim",
}
+23
View File
@@ -0,0 +1,23 @@
{
"$schema": "https://raw.githubusercontent.com/DavidAnson/markdownlint/main/schema/markdownlint-config-schema.json",
"blanks-around-headings": {
"lines_below": 0
},
"ul-style": {
"style": "sublist"
},
"ol-prefix": {
"style": "ordered"
},
"line-length": {
"tables": false,
"code_blocks": false
},
"no-inline-html": {
"allowed_elements": ["div", "img", "details", "summary", "kbd", "a", "br"]
},
"ul-indent": false,
"no-hard-tabs": false,
"blanks-around-lists": false,
"first-line-heading": false
}
+22
View File
@@ -0,0 +1,22 @@
{
"$schema": "https://biomejs.dev/schemas/1.4.0/schema.json",
"organizeImports": {
"enabled": true
},
"formatter": {
"enabled": true,
"lineWidth": 120,
"indentStyle": "space",
"indentWidth": 2,
"formatWithErrors": true
},
"javascript": {
"globals": ["ObjC", "Application", "delay", "Path", "$"]
},
"linter": {
"enabled": true,
"rules": {
"all": true
}
}
}
@@ -33,5 +33,10 @@
"body": ["> [!WARNING]", "> $0"],
"description": "https://docs.github.com/en/get-started/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax#alerts",
"prefix": "warning (callout)"
},
"div": {
"body": ["<div>{$0}</div>"],
"description": "https://developer.mozilla.org/en-US/docs/Web/HTML/Element/div",
"prefix": ["div"]
}
}
+2
View File
@@ -18,6 +18,8 @@ configuration {
}
* {
background: #1E1F29FF;
background-alt: #282A36FF;