Compare commits

...

19 Commits

Author SHA1 Message Date
github-actions[bot]
b8a4b82431 chore: update pre-commit hooks (#63) 2025-01-06 13:44:20 +02:00
0b03acebd8 feat(config): tmux plugin tmux-fzf-url 2025-01-02 22:22:59 +02:00
d172b86cb8 chore(docs): update nvim, tmux, wezterm keymaps 2025-01-02 17:46:07 +02:00
f910dfb9ac chore(nvim): add lazy dev path, enable profiling 2025-01-02 17:36:53 +02:00
ee95d57ba0 chore(config): aerospace tweaks 2025-01-02 17:34:48 +02:00
f8a317f3c7 chore(dfm): install script cleanup 2025-01-02 15:18:48 +02:00
3762e10932 chore(config): aerospace docker desktop layout 2025-01-02 14:53:59 +02:00
afda96902b chore(config): ghostty tweaks 2025-01-02 14:53:20 +02:00
3060b6ad66 chore(nvim): mason tools, sessionopts 2025-01-02 14:15:06 +02:00
github-actions[bot]
4f154cf509 chore: update pre-commit hooks (#62)
Co-authored-by: ivuorinen <11024+ivuorinen@users.noreply.github.com>
2025-01-02 11:41:43 +02:00
863d803483 feat(config): zed config 2024-12-30 17:53:56 +02:00
07bb2b56d1 feat(config): glow config 2024-12-30 17:51:47 +02:00
84a753100e feat(config): ghostty config 2024-12-30 17:51:26 +02:00
c8b01f3fda chore(config): aerospace tweaks 2024-12-30 17:50:47 +02:00
8e6a110aac chore(ci): pre-commit - detect-aws-creds 2024-12-30 17:49:50 +02:00
a8baa1671f chore(config): fix terminfo, add ghostty inits 2024-12-30 17:27:45 +02:00
2ccdd042f6 chore: sort gitignore, echo submodule ignore status 2024-12-30 17:26:35 +02:00
github-actions[bot]
8cf43ed555 chore: update pre-commit hooks (#60)
Co-authored-by: ivuorinen <11024+ivuorinen@users.noreply.github.com>
2024-12-30 15:05:15 +02:00
e22094e0da fix(dfm): asdf plugin-install, docs translations 2024-12-30 11:26:54 +02:00
24 changed files with 469 additions and 203 deletions

45
.gitignore vendored
View File

@@ -1,32 +1,35 @@
Brewfile.lock.json
lazy-lock.json
config/nvim/lazy-lock.json
*.log
!.gitkeep
*-secret
*.bak
*.log
*.socket
*cache
.env
.idea
.nfs*
.vscode
Brewfile.lock.json
antidote_plugins.zsh
config/alacritty/theme-active.toml
config/cheat/cheatsheets/pure-bash-bible/*
config/cheat/cheatsheets/tldr/*
config/git/credentials
config/npm/npmrc
config/zsh/.zcompdump
config/alacritty/theme-active.toml
ssh/local.d/*
!ssh/local.d/.gitkeep
!.gitkeep
.env
local/share/fonts/*
node_modules
.nfs*
*.socket
iTermServer-*
lock
config/iterm2/AppSupport
config/gnupg/S.*
config/gnupg/s
config/gnupg/private-keys-v1.d
config/gnupg/s
config/iterm2/AppSupport
config/npm/npmrc
config/nvim/lazy-lock.json
config/nvim/spell/*
!config/nvim/spell/.gitkeep
antidote_plugins.zsh
*.bak
config/zed/*
!config/zed/settings.json
config/zsh/.zcompdump
iTermServer-*
lazy-lock.json
local/share/fonts/*
local/bin/asdf/plugins/*
lock
node_modules
ssh/local.d/*
!ssh/local.d/.gitkeep

View File

@@ -3,6 +3,7 @@ repos:
rev: v5.0.0
hooks:
- id: requirements-txt-fixer
- id: detect-aws-credentials
- id: detect-private-key
- id: trailing-whitespace
args: [--markdown-linebreak-ext=md]
@@ -25,7 +26,7 @@ repos:
rev: v0.43.0
hooks:
- id: markdownlint
args: [-c, .markdownlint.yaml, --fix]
args: [-c, .markdownlint.json, --fix]
- repo: https://github.com/adrienverge/yamllint
rev: v1.35.1
@@ -43,12 +44,12 @@ repos:
- id: shfmt
- repo: https://github.com/rhysd/actionlint
rev: v1.7.4
rev: v1.7.6
hooks:
- id: actionlint
- repo: https://github.com/renovatebot/pre-commit-hooks
rev: 39.82.9
rev: 39.91.0
hooks:
- id: renovate-config-validator

View File

@@ -24,3 +24,7 @@ disable=SC1091
# SC2174: When used with -p, -m only applies to the deepest directory.
# https://github.com/koalaman/shellcheck/wiki/SC2174
disable=SC2174
# SC2016: Expressions don't expand in single quotes, use double quotes for that.
# https://www.shellcheck.net/wiki/SC2016
disable=SC2016

View File

@@ -45,6 +45,7 @@ git submodule add --name tmux/tmux-dark-notify \
# Takes submodules and sets them to ignore all changes
for MODULE in $(git config --file .gitmodules --get-regexp path | awk '{ print $2 }'); do
echo "Ignoring submodule changes for submodule.${MODULE}..."
git config "submodule.${MODULE}.ignore" all
done

View File

@@ -7,6 +7,10 @@ export SHARED_SCRIPTS_SOURCED=0
source "$DOTFILES/config/shared.sh"
if [ -n "${GHOSTTY_RESOURCES_DIR}" ]; then
builtin source "${GHOSTTY_RESOURCES_DIR}/shell-integration/bash/ghostty.bash"
fi
# shellcheck source=../config/fzf/fzf.bash
[ -f "${DOTFILES}/config/fzf/fzf.bash" ] &&
source "${DOTFILES}/config/fzf/fzf.bash"

View File

@@ -45,6 +45,10 @@ setup_tmux_window_name_plugin()
fi
}
if [[ -n $GHOSTTY_RESOURCES_DIR ]]; then
source "$GHOSTTY_RESOURCES_DIR"/shell-integration/zsh/ghostty-integration
fi
source_fzf_config
setup_tmux_window_name_plugin
x-have antidot && eval "$(antidot init)"

View File

@@ -39,41 +39,53 @@ automatically-unhide-macos-hidden-apps = true
# check-further-callbacks = true
# run = ['layout floating', 'move-node-to-workspace S'] # The callback itself
[[on-window-detected]]
if.app-name-regex-substring = 'settings' # All settings
run = ['layout floating']
[[on-window-detected]]
if.app-id = 'org.ferdium.ferdium-app' # Ferdium, has WhatsApp etc.
run = ['layout floating']
[[on-window-detected]]
if.app-name-regex-substring = 'finder'
run = 'layout floating'
[[on-window-detected]]
if.app-id = 'com.apple.finder' # Finder
run = 'layout floating'
run = ['layout floating']
[[on-window-detected]]
if.app-id = 'com.apple.mail' # Mail
run = 'layout floating'
run = ['layout floating']
[[on-window-detected]]
if.app-id = 'com.DanPristupov.Fork' # Fork
run = 'layout floating'
run = ['layout floating']
[[on-window-detected]]
if.app-id = 'com.flexibits.fantastical2.mac' # Fantastical
run = 'layout floating'
run = ['layout floating']
[[on-window-detected]]
if.app-id = 'org.whispersystems.signal-desktop' # Signal
run = 'layout floating'
run = ['layout floating']
[[on-window-detected]]
if.app-id = 'com.tidal.desktop'
run = ['layout floating', 'move-node-to-workspace 2']
if.app-id = 'com.tidal.desktop' # TIDAL
run = ['layout floating', 'move-node-to-workspace 2'] # Float and move to workspace 2
[[on-window-detected]]
if.app-id = 'com.apple.TV'
run = 'layout floating'
if.app-id = 'com.apple.TV' # Apple TV app
run = ['layout floating']
[[on-window-detected]]
if.app-id = 'com.setapp.DesktopClient' # Setapp
run = ['layout floating']
[[on-window-detected]]
if.app-id = 'com.electron.dockerdesktop' # Docker Desktop
run = ['layout floating']
[[on-window-detected]]
if.app-id = 'com.tinyspeck.slackmacgap' # Slack
run = ['layout floating']
# Possible values: (qwerty|dvorak)
# See https://nikitabobko.github.io/AeroSpace/guide#key-mapping
@@ -90,7 +102,6 @@ preset = 'qwerty'
[gaps]
inner.horizontal = 5
inner.vertical = 5
# outer.top = 0
outer.top = [{ monitor.'^built-in retina display$' = 0 }, 0]
outer.right = 0
outer.bottom = 0
@@ -126,13 +137,9 @@ outer.left = 0
# end tell'
# '''
alt-cmd-shift-f = 'fullscreen'
alt-cmd-f = 'layout floating'
alt-cmd-left = 'join-with left'
alt-cmd-down = 'join-with down'
alt-cmd-up = 'join-with up'
alt-cmd-right = 'join-with right'
# alt-cmd-shift-f = 'fullscreen'
# alt-shift-f = 'layout floating'
# alt-shift-tab = 'move-workspace-to-monitor --wrap-around next'
# See: https://nikitabobko.github.io/AeroSpace/commands#focus
alt-h = 'focus left'
@@ -140,48 +147,66 @@ alt-j = 'focus down'
alt-k = 'focus up'
alt-l = 'focus right'
# See: https://nikitabobko.github.io/AeroSpace/commands#move
alt-shift-h = 'move left'
alt-shift-j = 'move down'
alt-shift-k = 'move up'
alt-shift-l = 'move right'
# See: https://nikitabobko.github.io/AeroSpace/commands#workspace
cmd-shift-1 = 'workspace 1' # Main
cmd-shift-2 = 'workspace 2' # Music
alt-shift-1 = 'workspace 1' # Main
alt-shift-2 = 'workspace 2' # Media
ctrl-shift-1 = 'move-node-to-workspace 1'
ctrl-shift-2 = 'move-node-to-workspace 2'
# See: https://nikitabobko.github.io/AeroSpace/commands#move-node-to-workspace
alt-cmd-1 = 'move-node-to-workspace 1 --focus-follows-window'
alt-cmd-2 = 'move-node-to-workspace 2 --focus-follows-window'
shift-tab = 'workspace-back-and-forth'
# alt-shift-tab = 'move-workspace-to-monitor --wrap-around next'
alt-shift-tab = 'workspace-back-and-forth'
ctrl-shift-tab = 'move-workspace-to-monitor --wrap-around prev'
# See: https://nikitabobko.github.io/AeroSpace/commands#mode
# See: https://nikitabobko.github.io/AeroSpace/guide#binding-modes
alt-a = 'mode apps'
alt-s = 'mode service'
alt-d = 'mode resize'
alt-m = 'mode move'
# ╭──────────────────────────────────────────────────────────╮
# │ alt-m │
# ╰──────────────────────────────────────────────────────────╯
[mode.move.binding]
esc = ['reload-config', 'mode main']
# See: https://nikitabobko.github.io/AeroSpace/commands#move-node-to-workspace
1 = ['move-node-to-workspace 1 --focus-follows-window']
2 = ['move-node-to-workspace 2 --focus-follows-window']
# See: https://nikitabobko.github.io/AeroSpace/commands#move
h = 'move left'
j = 'move down'
k = 'move up'
l = 'move right'
# See: https://nikitabobko.github.io/AeroSpace/commands#join-with
shift-h = 'join-with left'
shift-j = 'join-with down'
shift-k = 'join-with up'
shift-l = 'join-with right'
# https://nikitabobko.github.io/AeroSpace/commands#resize
ctrl-h = 'resize smart -70'
ctrl-l = 'resize smart +70'
shift-left = 'resize smart +70'
shift-right = 'resize smart -70'
# https://nikitabobko.github.io/AeroSpace/commands#flatten-workspace-tree
r = ['flatten-workspace-tree', 'mode main'] # reset layout
# ╭──────────────────────────────────────────────────────────╮
# │ alt-a │
# ╰──────────────────────────────────────────────────────────╯
[mode.apps.binding]
esc = ['reload-config', 'mode main']
alt-b = ['exec-and-forget open -a /Applications/Brave Browser.app', 'mode main']
alt-c = ['exec-and-forget open -a /Applications/Ferdium.app', 'mode main']
alt-o = ['exec-and-forget open -a /Applications/Obsidian.app', 'mode main']
alt-s = ['exec-and-forget open -a /Applications/Slack.app', 'mode main']
alt-t = ['exec-and-forget open -a /Applications/TIDAL.app', 'mode main']
alt-w = ['exec-and-forget open -a /Applications/WezTerm.app', 'mode main']
b = ['exec-and-forget open -a /Applications/Brave Browser.app', 'mode main'] # Browser
c = ['exec-and-forget open -a /Applications/Ferdium.app', 'mode main'] # Chat
g = ['exec-and-forget open -a /Applications/Ghostty.app', 'mode main'] # Ghostty
o = ['exec-and-forget open -a /Applications/Obsidian.app', 'mode main'] # Obsidian
s = ['exec-and-forget open -a /Applications/Slack.app', 'mode main'] # Slack
t = ['exec-and-forget open -a /Applications/TIDAL.app', 'mode main'] # Tidal
w = ['exec-and-forget open -a /Applications/WezTerm.app', 'mode main'] # WezTerm
# ╭──────────────────────────────────────────────────────────╮
# │ alt-s │
# ╰──────────────────────────────────────────────────────────╯
[mode.service.binding]
esc = ['reload-config', 'mode main']
esc = ['reload-config', 'mode main'] # reload config
r = ['flatten-workspace-tree', 'mode main'] # reset layout
# See: https://nikitabobko.github.io/AeroSpace/commands#layout
f = ['layout floating tiling', 'mode main'] # Toggle between floating and tiling layout
backspace = ['close-all-windows-but-current', 'mode main']
[mode.resize.binding]
# See: https://nikitabobko.github.io/AeroSpace/commands#resize
r = ['flatten-workspace-tree', 'mode main'] # reset layout
h = 'resize smart -70'
l = 'resize smart +70'
esc = ['reload-config', 'mode main']

View File

@@ -281,8 +281,8 @@ export LESSHISTFILE="$XDG_STATE_HOME"/less/history
# export LESS_TERMCAP_md="$ORANGE"
# zsh autoloaded terminfo
export TERMINFO="${XDG_DATA_HOME}/terminfo"
export TERMINFO_DIRS="${XDG_DATA_HOME}/terminfo":/usr/share/terminfo
# export TERMINFO="${XDG_DATA_HOME}/terminfo"
# export TERMINFO_DIRS="${XDG_DATA_HOME}/terminfo":/usr/share/terminfo
# Don't clear the screen after quitting a manual page
export MANPAGER="less -X"

15
config/ghostty/config Normal file
View File

@@ -0,0 +1,15 @@
# vim: ft=ghostty
theme = "light:tokyonight-day,dark:tokyonight-storm"
font-family = "JetBrainsMono Nerd Font Mono"
background-blur-radius = 15
background-opacity = 0.95
clipboard-read = allow
clipboard-write = allow
cursor-style = bar
custom-shader-animation = true
gtk-single-instance = true
mouse-hide-while-typing = true
shell-integration-features = true
window-theme = system

6
config/glow/glow.yml Normal file
View File

@@ -0,0 +1,6 @@
# mouse support (TUI-mode only)
mouse: false
# use pager to display markdown
pager: true
# word-wrap at width
width: 80

View File

@@ -52,9 +52,15 @@ require('lazy').setup(
-- No need to notify about changes
notify = false,
},
dev = {
path = '~/Code/nvim', -- Load wip plugins from this path
},
install = {
colorscheme = { vim.g.colors_theme },
},
profiling = {
loader = true,
},
}
)

View File

@@ -39,7 +39,7 @@ o.termguicolors = true -- Enable GUI colors
o.timeoutlen = 250 -- Decrease mapped sequence wait time
o.updatetime = 250 -- 250 ms = 2,5 seconds
o.sessionoptions =
'blank,buffers,curdir,folds,help,tabpages,winsize,winpos,terminal,localoptions'
'buffers,curdir,folds,tabpages,winsize,winpos,terminal,localoptions'
-- Enable the colorcolumn
vim.api.nvim_set_option_value('colorcolumn', '+1', { scope = 'global' })

View File

@@ -196,12 +196,16 @@ return {
'goimports',
'gotests',
'phpcbf',
'phpmd',
'phpstan',
'pint',
'prettierd',
'semgrep',
'shellcheck',
'shfmt',
'staticcheck',
'stylua',
'trivy',
'vint',
'yamlfmt',
},
@@ -284,6 +288,8 @@ return {
validate = { enable = true },
},
}
-- end of junnplus/lsp-setup config
end,
},
@@ -317,6 +323,11 @@ return {
else
lsp_format_opt = 'fallback'
end
-- Disable autoformat for files in a certain path
local bufname = vim.api.nvim_buf_get_name(bufnr)
if bufname:match '/node_modules/' then return end
return {
timeout_ms = 500,
lsp_format = lsp_format_opt,
@@ -326,6 +337,7 @@ return {
lua = { 'stylua' },
sh = { 'shfmt' },
bash = { 'shfmt' },
php = { 'phpcbf' },
-- Conform can also run multiple formatters sequentially
-- python = { "isort", "black" },
--
@@ -333,6 +345,10 @@ return {
-- javascript = { "prettierd", "prettier", stop_after_first = true },
},
},
init = function()
-- If you want the formatexpr, here is the place to set it
vim.o.formatexpr = "v:lua.require'conform'.formatexpr()"
end,
},
-- Automatically install formatters registered with conform.nvim via mason.nvim
-- https://github.com/zapling/mason-conform.nvim

View File

@@ -0,0 +1 @@
https://wfxr.mit-license.org/2018

View File

@@ -0,0 +1,64 @@
#!/usr/bin/env bash
#===============================================================================
# Author: Wenxuan
# Email: wenxuangm@gmail.com
# Created: 2018-04-06 12:12
#===============================================================================
get_fzf_options()
{
local fzf_options
local fzf_default_options='-w 100% -h 50% --multi -0 --no-preview'
fzf_options="$(tmux show -gqv '@fzf-url-fzf-options')"
[ -n "$fzf_options" ] && echo "$fzf_options" || echo "$fzf_default_options"
}
fzf_filter()
{
eval "fzf-tmux $(get_fzf_options)"
}
custom_open=$3
open_url()
{
if [[ -n $custom_open ]]; then
$custom_open "$@"
elif hash xdg-open &> /dev/null; then
nohup xdg-open "$@"
elif hash open &> /dev/null; then
nohup open "$@"
elif [[ -n $BROWSER ]]; then
nohup "$BROWSER" "$@"
fi
}
limit='screen'
[[ $# -ge 2 ]] && limit=$2
if [[ $limit == 'screen' ]]; then
content="$(tmux capture-pane -J -p -e | sed -r 's/\x1B\[[0-9;]*[mK]//g'))"
else
content="$(tmux capture-pane -J -p -e -S -"$limit" | sed -r 's/\x1B\[[0-9;]*[mK]//g'))"
fi
urls=$(echo "$content" | grep -oE '(https?|ftp|file):/?//[-A-Za-z0-9+&@#/%?=~_|!:,.;]*[-A-Za-z0-9+&@#/%=~_|]')
wwws=$(echo "$content" | grep -oE '(http?s://)?www\.[a-zA-Z](-?[a-zA-Z0-9])+\.[a-zA-Z]{2,}(/\S+)*' | grep -vE '^https?://' | sed 's/^\(.*\)$/http:\/\/\1/')
ips=$(echo "$content" | grep -oE '[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}(:[0-9]{1,5})?(/\S+)*' | sed 's/^\(.*\)$/http:\/\/\1/')
gits=$(echo "$content" | grep -oE '(ssh://)?git@\S*' | sed 's/:/\//g' | sed 's/^\(ssh\/\/\/\)\{0,1\}git@\(.*\)$/https:\/\/\2/')
gh=$(echo "$content" | grep -oE "['\"]([_A-Za-z0-9-]*/[_.A-Za-z0-9-]*)['\"]" | sed "s/['\"]//g" | sed 's#.#https://github.com/&#')
if [[ $# -ge 1 && $1 != '' ]]; then
extras=$(echo "$content" | eval "$1")
fi
items=$(
printf '%s\n' "${urls[@]}" "${wwws[@]}" "${gh[@]}" "${ips[@]}" "${gits[@]}" "${extras[@]}" \
| grep -v '^$' \
| sort -u \
| nl -w3 -s ' '
)
[ -z "$items" ] && tmux display 'tmux-fzf-url: no URLs found' && exit
fzf_filter <<< "$items" | awk '{print $2}' \
| while read -r chosen; do
open_url "$chosen" &> "/tmp/tmux-$(id -u)-fzf-url.log"
done

View File

@@ -0,0 +1,23 @@
#!/usr/bin/env bash
#===============================================================================
# Author: Wenxuan
# Email: wenxuangm@gmail.com
# Created: 2018-04-06 09:30
#===============================================================================
SCRIPT_DIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
# $1: option
# $2: default value
tmux_get() {
local value
value="$(tmux show -gqv "$1")"
[ -n "$value" ] && echo "$value" || echo "$2"
}
key="$(tmux_get '@fzf-url-bind' 'u')"
history_limit="$(tmux_get '@fzf-url-history-limit' 'screen')"
extra_filter="$(tmux_get '@fzf-url-extra-filter' '')"
custom_open="$(tmux_get '@fzf-url-open' '')"
echo "$extra_filter" >/tmp/filter
tmux bind-key "$key" run -b "$SCRIPT_DIR/fzf-url.sh '$extra_filter' $history_limit '$custom_open'"

View File

@@ -159,6 +159,10 @@ set -g @mode_indicator_copy_mode_style 'bg=default,fg=yellow'
set -g @mode_indicator_empty_mode_style 'bg=default,fg=#7aa2f7'
set -g @mode_indicator_sync_mode_style 'bg=default,fg=red'
# https://github.com/wfxr/tmux-fzf-url
set -g @fzf-url-bind 'u'
set -g @fzf-url-history-limit '2000'
# ╭──────────────────────────────────────────────────────────╮
# │ Plugins │
# ╰──────────────────────────────────────────────────────────╯
@@ -172,7 +176,7 @@ run-shell ~/.dotfiles/config/tmux/plugins/tmux-suspend/suspend.tmux
run-shell ~/.dotfiles/config/tmux/plugins/tmux-yank/yank.tmux
run-shell ~/.dotfiles/config/tmux/plugins/tmux-current-pane-hostname/current_pane_hostname.tmux
run-shell ~/.dotfiles/config/tmux/plugins/tmux-dark-notify/main.tmux
run-shell ~/.dotfiles/config/tmux/plugins/tmux-fzf-url/fzf-url.tmux
if-shell "test -e $HOME/.local/state/tmux/tmux-dark-notify-theme.conf" \
"source-file $HOME/.local/state/tmux/tmux-dark-notify-theme.conf"

57
config/zed/settings.json Normal file
View File

@@ -0,0 +1,57 @@
{
"formatter": {
"external": {
"command": "node_modules/.bin/prettier",
"arguments": [
"--stdin-filepath",
"{buffer_path}"
]
}
},
"languages": {
"Lua": {
"enable_language_server": true,
"tab_size": 2
}
},
"lsp": {
"gopls": {
"initialization_options": {
"hints": {
"assignVariableTypes": true,
"compositeLiteralFields": true,
"compositeLiteralTypes": true,
"constantValues": true,
"functionTypeParameters": true,
"parameterNames": true,
"rangeVariableTypes": true
}
}
}
},
"preferred_line_length": 100,
"format_on_save": "on",
"vim_mode": true,
"theme": {
"mode": "system",
"light": "Tokyo Night Light",
"dark": "Tokyo Night Storm"
},
"inlay_hints": {
"enabled": true,
"show_type_hints": true,
"show_parameter_hints": true,
"show_other_hints": true
},
"ui_font_size": 16,
"buffer_font_size": 16,
"buffer_font_fallbacks": [
"JetBrainsMono Nerd Font"
],
"inline_completions": {
"disabled_globs": [
".env"
]
},
"hour_format": "hour24"
}

View File

@@ -55,20 +55,15 @@ _dfm()
'cargo:Install rust/cargo packages'
'cheat-databases:Install cheat external cheatsheet databases'
'composer:Install composer'
'dotenv:Install dotenv-linter'
'fonts:Install programming fonts'
'gh:Install GitHub CLI Extensions'
'go:Install Go Packages'
'imagick:Install ImageMagick CLI'
'starship:Install starship.rs'
'macos:Setup nice macOS defaults'
'neofetch:Install neofetch'
'nvm:Install Node Version Manager'
'nvm-latest:Install latest LTS node'
'npm:Install NPM Packages'
'npm-packages:Install NPM Packages'
'ntfy:Install ntfy'
'ohmybash:Install oh-my-bash'
'pip:Install pip/python packages'
'z:Install z'
)
_describe 'install commands' install_cmds

View File

@@ -2,62 +2,60 @@
```txt
x <Space> *@~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
x <Space> *@~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Query keys after "<Space>"
n <Space> *@~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
n <Space> *@~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Query keys after "<Space>"
x " *@~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
x " *@~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Query keys after """
n " *@~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
n " *@~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Query keys after """
x ' *@~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
x ' *@~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Query keys after "'"
n ' *@~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
n ' *@~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Query keys after "'"
x ` *@~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
x ` *@~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Query keys after "`"
n ` *@~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
n ` *@~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Query keys after "`"
x g *@~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
x g *@~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Query keys after "g"
n g *@~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
n g *@~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Query keys after "g"
x z *@~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
x z *@~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Query keys after "z"
n z *@~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
n z *@~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Query keys after "z"
n <C-W> *@~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
n <C-W> *@~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Query keys after "<C-W>"
n <Esc><Esc> * :nohlsearch<CR>
Clear Search Highlighting
n <Space>qQ * :q!<CR>
n <Space>qQ * ~/.config/nvim/lua/keymaps.lua
Force quit without saving
n <Space>qw * :wq<CR>
Write and quit
n <Space>qq * :wq!<CR>
n <Space>qq * ~/.config/nvim/lua/keymaps.lua
Quit with force saving
n <Space>qf * :q<CR>
Quicker close split
n <Space>tn * :Noice dismiss<CR>
Noice: Dismiss Notification
n <Space>tl * :lua vim.o.bg = vim.o.bg:get() == "light" and "dark" or "light"<CR>
n <Space>tl * ~/.config/nvim/lua/utils.lua
Toggle Light/Dark Mode
n <Space>te * :Neotree toggle<CR>
Toggle Neotree
n <Space>tc * :CloakToggle<CR>
Cloak: Toggle
n <Space>o * ~/.config/nvim/lua/keymaps.lua
Open repo in browser
n <Space>xx * :Trouble diagnostics<CR>
Trouble: Diagnostic
Diagnostic
n <Space>xw * :Trouble workspace_diagnostics<CR>
Trouble: Workspace Diagnostics
Workspace Diagnostics
n <Space>xq * :Trouble quickfix<CR>
Trouble: Quickfix
Quickfix
n <Space>xl * :Trouble loclist<CR>
Trouble: Location List
Location List
n <Space>xd * :Trouble document_diagnostics<CR>
Trouble: Document Diagnostics
Document Diagnostics
n <Space>sx * :Telescope import<CR>
Telescope: Import
n <Space>sw * :Telescope grep_string<CR>
@@ -76,8 +74,8 @@ n <Space>sl * :Telescope luasnip<CR>
Search LuaSnip
n <Space>sk * :Telescope keymaps<CR>
Search Keymaps
n <Space>sh * :Telescope highlights<CR>
List Highlights
n <Space>sh * :Telescope help_tags<CR>
Help tags
n <Space>sg * :Telescope live_grep<CR>
Search by Grep
n <Space>sd * :Telescope diagnostics<CR>
@@ -122,10 +120,8 @@ n <Space>cl * :Lspsaga show_cursor_diagnostics<CR>
Cursor Diagnostics
n <Space>ci * :Lspsaga implement<CR>
Implementations
x <Space>cf * :lua vim.lsp.buf.format()<CR>
Format
n <Space>cf * :lua vim.lsp.buf.format()<CR>
Format
n <Space>cg * :lua require("neogen").generate()<CR>
Generate annotations
n <Space>cd * :Lspsaga show_line_diagnostics<CR>
Line Diagnostics
n <Space>cco * :Lspsaga outgoing_calls<CR>
@@ -134,8 +130,6 @@ n <Space>cci * :Lspsaga incoming_calls<CR>
Incoming Calls
n <Space>ca * :Lspsaga code_action<CR>
Code Action
n <Space>cg * :lua require("neogen").generate()<CR>
Generate annotations
n <Space>bw * :lua MiniBufremove.wipeout()<CR>
Wipeout
n <Space>bl * :bnext<CR>
@@ -148,6 +142,34 @@ n <Space>bh * :bprev<CR>
Prev
n <Space>bd * :lua MiniBufremove.delete()<CR>
Delete
n <Space>ba * :%bd|e#|bd#<CR>
Close all except current
n <Space>o * ~/.config/nvim/lua/keymaps.lua
Open repo in browser
n <Space>tmw * <Cmd>setlocal wrap! wrap?<CR>
Toggle 'wrap'
n <Space>tms * <Cmd>setlocal spell! spell?<CR>
Toggle 'spell'
n <Space>tmr * <Cmd>setlocal relativenumber! relativenumber?<CR>
Toggle 'relativenumber'
n <Space>tmn * <Cmd>setlocal number! number?<CR>
Toggle 'number'
n <Space>tml * <Cmd>setlocal list! list?<CR>
Toggle 'list'
n <Space>tmi * <Cmd>setlocal ignorecase! ignorecase?<CR>
Toggle 'ignorecase'
n <Space>tmh * <Cmd>let v:hlsearch = 1 - v:hlsearch | echo (v:hlsearch ? " " : "no") . "hlsearch"<CR>
Toggle search highlight
n <Space>tmd * <Cmd>lua print(MiniBasics.toggle_diagnostic())<CR>
Toggle diagnostic
n <Space>tmC * <Cmd>setlocal cursorcolumn! cursorcolumn?<CR>
Toggle 'cursorcolumn'
n <Space>tmc * <Cmd>setlocal cursorline! cursorline?<CR>
Toggle 'cursorline'
n <Space>tmb * <Cmd>lua vim.o.bg = vim.o.bg == "dark" and "light" or "dark"; print(vim.o.bg)<CR>
Toggle 'background'
<Space>cf * ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua
Format buffer
x # * vim/_defaults.lua
:help v_#-default
o % <Plug>(MatchitOperationForward)
@@ -157,7 +179,7 @@ n & * :&&<CR>
:help &-default
x * * vim/_defaults.lua
:help v_star-default
o ; * ~/.local/share/nvim/lazy/mini.jump/lua/mini/jump.lua
o ; * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/jump.lua
Repeat jump
x ; * <Cmd>lua MiniJump.jump()<CR>
Repeat jump
@@ -171,11 +193,11 @@ v > * >gv
Indent Right
n > * >gv
Indent Right
n @ * ~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
n @ * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Execute macro without 'mini.clue' triggers
x @ * mode() == 'V' ? ':normal! @'.getcharstr().'<CR>' : '@'
:help v_@-default
o F * ~/.local/share/nvim/lazy/mini.jump/lua/mini/jump.lua
o F * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/jump.lua
Jump backward
x F * <Cmd>lua MiniJump.smart_jump(true, false)<CR>
Jump backward
@@ -183,11 +205,11 @@ n F * <Cmd>lua MiniJump.smart_jump(true, false)<CR>
Jump backward
n K * :Lspsaga hover_doc<CR>
Hover Documentation
n Q * ~/.local/share/nvim/lazy/mini.clue/lua/mini/clue.lua
n Q * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/clue.lua
Execute macro without 'mini.clue' triggers
x Q * mode() == 'V' ? ':normal! @<C-R>=reg_recorded()<CR><CR>' : 'Q'
:help v_Q-default
o T * ~/.local/share/nvim/lazy/mini.jump/lua/mini/jump.lua
o T * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/jump.lua
Jump backward till
x T * <Cmd>lua MiniJump.smart_jump(true, true)<CR>
Jump backward till
@@ -197,10 +219,10 @@ n Y * y$
:help Y-default
n Zk * ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua
Flash Treesitter
x Zk * ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua
Flash Treesitter
o Zk * ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua
Flash Treesitter
x Zk * ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua
Flash Treesitter
o [% <Plug>(MatchitOperationMultiBackward)
x [% <Plug>(MatchitVisualMultiBackward)
n [% <Plug>(MatchitNormalMultiBackward)
@@ -252,7 +274,7 @@ o ai * <Cmd>lua MiniIndentscope.textobject(true)<CR>
Object scope with border
x ai * <Cmd>lua MiniIndentscope.textobject(true)<CR>
Object scope with border
o f * ~/.local/share/nvim/lazy/mini.jump/lua/mini/jump.lua
o f * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/jump.lua
Jump forward
x f * <Cmd>lua MiniJump.smart_jump(false, false)<CR>
Jump forward
@@ -263,16 +285,10 @@ n gR * :RegexplainerToggle<CR>
o g% <Plug>(MatchitOperationBackward)
x g% <Plug>(MatchitVisualBackward)
n g% <Plug>(MatchitNormalBackward)
o gh * <Cmd>lua MiniDiff.textobject()<CR>
Hunk range textobject
x gH * ~/.local/share/nvim/lazy/mini.diff/lua/mini/diff.lua
Reset hunks
n gH * ~/.local/share/nvim/lazy/mini.diff/lua/mini/diff.lua
Reset hunks
x gh * ~/.local/share/nvim/lazy/mini.diff/lua/mini/diff.lua
Apply hunks
n gh * ~/.local/share/nvim/lazy/mini.diff/lua/mini/diff.lua
Apply hunks
x gS * :<C-U>lua MiniSplitjoin.toggle({ region = MiniSplitjoin.get_visual_region() })<CR>
Toggle arguments
n gS * v:lua.MiniSplitjoin.operator("toggle") . " "
Toggle arguments
x gs * <Cmd>lua MiniOperators.sort('visual')<CR>
Sort selection
n gss ^gsg_
@@ -299,17 +315,39 @@ n g== g=_
Evaluate line
n g= * v:lua.MiniOperators.evaluate()
Evaluate operator
x gS * :<C-U>lua MiniSplitjoin.toggle({ region = MiniSplitjoin.get_visual_region() })<CR>
Toggle arguments
n gS * v:lua.MiniSplitjoin.operator("toggle") . " "
Toggle arguments
o gh * <Cmd>lua MiniDiff.textobject()<CR>
Hunk range textobject
x gH * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/diff.lua
Reset hunks
n gH * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/diff.lua
Reset hunks
x gh * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/diff.lua
Apply hunks
n gh * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/diff.lua
Apply hunks
x g/ * <Esc>/\%V
Search inside visual selection
n gV * "`[" . strpart(getregtype(), 0, 1) . "`]"
Visually select changed text
x gp * "+P
Paste from system clipboard
n gp * "+p
Paste from system clipboard
x gy * "+y
Copy to system clipboard
n gy * "+y
Copy to system clipboard
n go * v:lua.MiniBasics.put_empty_line(v:false)
Put empty line below
n gO * v:lua.MiniBasics.put_empty_line(v:true)
Put empty line above
o gc * <Cmd>lua MiniComment.textobject()<CR>
Comment textobject
n gcc * ~/.local/share/nvim/lazy/mini.comment/lua/mini/comment.lua
n gcc * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/comment.lua
Comment line
x gc * ~/.local/share/nvim/lazy/mini.comment/lua/mini/comment.lua
x gc * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/comment.lua
Comment selection
n gc * ~/.local/share/nvim/lazy/mini.comment/lua/mini/comment.lua
n gc * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/comment.lua
Comment
x gx * <Cmd>lua MiniOperators.exchange('visual')<CR>
Exchange selection
@@ -319,47 +357,49 @@ o ii * <Cmd>lua MiniIndentscope.textobject(false)<CR>
Object scope
x ii * <Cmd>lua MiniIndentscope.textobject(false)<CR>
Object scope
x j * v:count == 0 ? 'gj' : 'j'
n j * v:count == 0 ? 'gj' : 'j'
Move down
x k * v:count == 0 ? 'gk' : 'k'
n k * v:count == 0 ? 'gk' : 'k'
Move up
n shn * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n shn * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Highlight next surrounding
n sFn * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n sFn * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Find next left surrounding
n sfn * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n sfn * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Find next right surrounding
n srn * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n srn * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Replace next surrounding
n sdn * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n sdn * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Delete next surrounding
n shl * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n shl * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Highlight previous surrounding
n sFl * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n sFl * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Find previous left surrounding
n sfl * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n sfl * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Find previous right surrounding
n srl * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n srl * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Replace previous surrounding
n sdl * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n sdl * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Delete previous surrounding
x sa * :<C-U>lua MiniSurround.add('visual')<CR>
Add surrounding to selection
n sn * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n sn * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Update `MiniSurround.config.n_lines`
n sh * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n sh * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Highlight surrounding
n sF * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n sF * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Find left surrounding
n sf * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n sf * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Find right surrounding
n sr * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n sr * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Replace surrounding
n sd * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n sd * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Delete surrounding
n sa * ~/.local/share/nvim/lazy/mini.surround/lua/mini/surround.lua
n sa * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/surround.lua
Add surrounding
o t * ~/.local/share/nvim/lazy/mini.jump/lua/mini/jump.lua
o t * ~/.local/share/nvim/lazy/mini.nvim/lua/mini/jump.lua
Jump forward till
x t * <Cmd>lua MiniJump.smart_jump(false, true)<CR>
Jump forward till
@@ -367,20 +407,10 @@ n t * <Cmd>lua MiniJump.smart_jump(false, true)<CR>
Jump forward till
x zk * ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua
Flash
n zk * ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua
Flash
o zk * ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua
Flash
n <C-W>= * <C-W>=
Equal Size Splits
n <C-W>+ * :resize +5<CR>
H Resize +
n <C-W>- * :resize -5<CR>
H Resize -
n <C-W>. * :vertical resize +10<CR>
V Resize +
n <C-W>, * :vertical resize -10<CR>
V Resize -
n zk * ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua
Flash
v <C-J> * :m '>+1<CR>gv=gv
Move Block Down
n <C-J> * :m '>+1<CR>gv=gv
@@ -389,12 +419,24 @@ v <C-K> * :m '<-2<CR>gv=gv
Move Block Up
n <C-K> * :m '<-2<CR>gv=gv
Move Block Up
n <C-S> * :w!<CR>
Save
n <C-W>= * <C-W>=
Equal Size Splits
n <C-W>+ * :resize +10<CR>
H Resize +
n <C-W>- * :resize -10<CR>
H Resize -
n <C-W>. * :vertical resize +10<CR>
V Resize +
n <C-W>, * :vertical resize -10<CR>
V Resize -
n <Down> * :echo "Use j to move!!"<CR>
?
n <Up> * :echo "Use k to move!!"<CR>
?
n <Right> * :echo "Use l to move!!"<CR>
?
n <Left> * :echo "Use h to move!!"<CR>
?
x <Plug>(MatchitVisualTextObject) <Plug>(MatchitVisualMultiBackward)o<Plug>(MatchitVisualMultiForward)
o <Plug>(MatchitOperationMultiForward) * :<C-U>call matchit#MultiMatch("W", "o")<CR>
o <Plug>(MatchitOperationMultiBackward) * :<C-U>call matchit#MultiMatch("bW", "o")<CR>
@@ -408,6 +450,7 @@ x <Plug>(MatchitVisualBackward) * :<C-U>call matchit#Match_wrapper('',0,'v')<CR
x <Plug>(MatchitVisualForward) * :<C-U>call matchit#Match_wrapper('',1,'v')<CR>:if col("''") != col("$") | exe ":normal! m'" | endif<CR>gv``
n <Plug>(MatchitNormalBackward) * :<C-U>call matchit#Match_wrapper('',0,'n')<CR>
n <Plug>(MatchitNormalForward) * :<C-U>call matchit#Match_wrapper('',1,'n')<CR>
n <Plug>PlenaryTestFile * :lua require('plenary.test_harness').test_file(vim.fn.expand("%:p"))<CR>
n <M-k> * <Cmd>lua MiniMove.move_line('up')<CR>
Move line up
n <M-j> * <Cmd>lua MiniMove.move_line('down')<CR>
@@ -424,7 +467,10 @@ x <M-l> * <Cmd>lua MiniMove.move_selection('right')<CR>
Move right
x <M-h> * <Cmd>lua MiniMove.move_selection('left')<CR>
Move left
n <Plug>PlenaryTestFile * :lua require('plenary.test_harness').test_file(vim.fn.expand("%:p"))<CR>
x <C-S> * <Esc><Cmd>silent! update | redraw<CR>
Save and go to Normal mode
n <C-S> * :w!<CR>
Save
n <C-W><C-D> <C-W>d
Show diagnostics under the cursor
n <C-W>d * vim/_defaults.lua
@@ -433,4 +479,4 @@ n <C-L> * :lua vim.lsp.buf.signature_help()<CR>
Signature
```
- Generated on Mon 9 Dec 2024 10:05:25 EET
- Generated on Thu 2 Jan 2025 17:41:13 EET

View File

@@ -2,17 +2,13 @@
Leader: `<ctrl><space>`
```
C-o Rotate through the panes
C-z Suspend the current client
```txt
Space Select next layout
# List all paste buffers
$ Rename current session
% Split window horizontally
& Kill current window
' Prompt for window index to select
( Switch to previous client
) Switch to next client
, Rename current window
- Delete the most recent paste buffer
. Move the current window
@@ -63,6 +59,8 @@ Leader: `<ctrl><space>`
M-3 Set the main-horizontal layout
M-4 Set the main-vertical layout
M-5 Select the tiled layout
M-6 Set the main-horizontal-mirrored layout
M-7 Set the main-vertical-mirrored layout
M-n Select the next window with an alert
M-o Rotate through the panes in reverse
M-p Select the previous window with an alert
@@ -70,6 +68,8 @@ Leader: `<ctrl><space>`
M-Down Resize the pane down by 5
M-Left Resize the pane left by 5
M-Right Resize the pane right by 5
C-o Rotate through the panes
C-z Suspend the current client
C-Up Resize the pane up
C-Down Resize the pane down
C-Left Resize the pane left

View File

@@ -277,4 +277,4 @@ Mouse: alt_screen
```
- Generated on Sat 10 Aug 2024 13:01:59 EEST
- Generated on Thu 2 Jan 2025 17:41:13 EET

View File

@@ -91,23 +91,19 @@ section_install()
MENU=(
"all:Installs everything in the correct order"
"asdf:Install asdf plugins"
"cargo:Install rust/cargo packages"
"cheat-databases:Install cheat external cheatsheet databases"
"composer:Install composer"
"dotenv:Install dotenv-linter"
"fonts:Install programming fonts"
"gh:Install GitHub CLI Extensions"
"go:Install Go Packages"
"imagick:Install ImageMagick CLI"
"macos:Setup nice macOS defaults"
"neofetch:Install neofetch"
"npm:Install NPM Packages"
"npm-packages:Install NPM Packages"
"ntfy:Install ntfy"
"nvm-latest:Install latest lts node using nvm"
"nvm:Install Node Version Manager (nvm)"
"ohmybash:Install oh-my-bash"
"pip:Install pip/python packages"
"starship:Install starship.rs"
"z:Install z"
)
@@ -131,7 +127,7 @@ section_install()
asdf)
msgr run "Installing asdf..."
$0 asdf plugins-add \
$0 asdf plugins-install \
&& msgr yay "asdf plugins installed!"
;;
@@ -161,12 +157,6 @@ section_install()
&& msgr yay "Installed fonts!"
;;
fzf)
msgr run "Installing fzf..."
bash "$DOTFILES/scripts/install-fzf.sh" \
&& msgr yay "fzf installed!"
;;
gh)
msgr run "Installing GitHub CLI Extensions..."
bash "$DOTFILES/scripts/install-gh-extensions.sh" \
@@ -355,30 +345,30 @@ section_asdf()
plugins-install)
msgr run "Installing plugins from configuration"
# Asennetaan ensin direnv jos sitä ei ole
# First install direnv if it's not installed
if ! asdf plugin list | grep -q "^direnv$"; then
msgr nested "Installing direnv plugin"
asdf plugin add direnv https://github.com/asdf-community/asdf-direnv.git
# Asennetaan direnv latest
# Install latest direnv
local latest_direnv
latest_direnv=$(asdf latest direnv)
asdf install direnv "$latest_direnv"
asdf global direnv "$latest_direnv"
fi
# Tarkistetaan että kaikki konfiguroidut pluginit on asennettu
# Check that all plugins are installed
local installed_plugins
installed_plugins=$(asdf plugin list)
while IFS= read -r line; do
# Ohita tyhjät rivit ja kommentit
# Skip empty lines and comments
[[ -z $line || $line =~ ^# ]] && continue
local plugin
plugin=$(echo "$line" | awk '{print $1}')
# Ohita direnv, käsiteltiin jo
# Skip direnv, it's already installed
[[ $plugin == "direnv" ]] && continue
if ! echo "$installed_plugins" | grep -q "^${plugin}$"; then
@@ -437,10 +427,11 @@ section_asdf()
local installed_plugins
installed_plugins=$(asdf plugin list | sort)
# Compare .tool-versions and installed plugins, remove unknown plugins from .tool-versions
# Compare .tool-versions and installed plugins,
# remove unknown plugins from .tool-versions
msgr nested "Updating tool-versions file"
while IFS= read -r line; do
# Säilytä kommentit ja tyhjät rivit
# Keep comments and empty lines
if [[ -z $line || $line =~ ^[[:space:]]*# ]]; then
echo "$line" >> "$temp_file"
continue
@@ -494,7 +485,6 @@ section_helpers()
"env:Show environment variables"
"functions:Show functions"
"nvim:Show nvim keybindings"
# shellcheck disable=SC2016
'path:Show $PATH dir by dir'
"tmux:Show tmux keybindings"
"wezterm:Show wezterm keybindings"

View File

@@ -23,7 +23,8 @@ generate_tmux_keybindings()
{
local tmux_keybindings_docs="$1"
local cb="\n\`\`\`\n"
local cb="\n\`\`\`txt\n"
local cbe="\n\`\`\`\n"
local kb
kb=$(tmux lsk -Tprefix -N | sed -e 's/^/ /;')
local h="# tmux keybindings\n"
@@ -33,7 +34,7 @@ generate_tmux_keybindings()
kb="${kb//$HOME/\$HOME}"
msg "Outputting tmux keybindings to $tmux_keybindings_docs"
echo -e "${h}${l}${cb}${kb}${cb}" > "$tmux_keybindings_docs"
echo -e "${h}${l}${cb}${kb}${cbe}" > "$tmux_keybindings_docs"
msg "Done!"
}