chore: clean up
9a6701b6
10 file(s) · +202 −144
| 1 | - | avm v0.30.1 (https://github.com/coral-xyz/anchor#8eec2e3b): |
|
| 2 | - | anchor |
|
| 3 | - | avm |
|
| 4 | - | create-gpui-app v0.1.5: |
|
| 5 | - | create-gpui-app |
|
| 6 | - | du-dust v1.2.0: |
|
| 7 | - | dust |
|
| 8 | - | lazy-etherscan v0.1.1: |
|
| 9 | - | lazy-etherscan |
|
| 10 | - | lstr v0.2.0: |
|
| 11 | - | lstr |
|
| 12 | - | postman2openapi-cli v1.2.1: |
|
| 13 | - | postman2openapi |
| 6 | 6 | (use-package base16-theme) |
|
| 7 | 7 | (use-package nord-theme) |
|
| 8 | 8 | ||
| 9 | - | (load-theme 'nord t) |
|
| 9 | + | (load-theme 'base16-nord t) |
|
| 10 | 10 | ||
| 11 | 11 | ;;; Mode line |
|
| 12 | 12 | ;; Evil's own indicator is dropped; the state is drawn by hand as a colored |
| 1 | + | [recipe.sesh] |
|
| 2 | + | command = "sesh list --json" |
|
| 3 | + | columns = ["Icon", "Name", "Path"] |
|
| 4 | + | keys.enter = { run = ["sesh", "connect", "{{.Name}}"], quit = true } |
|
| 5 | + | keys."ctrl+d" = ["tmux", "kill-session", "-t", "{{.Name}}"] |
|
| 6 | + | ||
| 7 | + | [recipe.nutiliti-worktrees] |
|
| 8 | + | command = "sesh worktree list -r Nutiliti/nutiliti --json" |
|
| 9 | + | columns = ["Number", "State", "Title"] |
|
| 10 | + | keys.enter = { run = ["sesh", "worktree", "connect", "{{.Number}}", "-r", "Nutiliti/nutiliti"], quit = true } |
|
| 11 | + | keys.o = ["gh", "browse", "{{.Number}}", "-R", "Nutiliti/nutiliti"] |
|
| 12 | + | cache = "10m" |
|
| 13 | + | colors = { State = { OPEN = "green", CLOSED = "red", MERGED = "magenta" } } |
|
| 14 | + | ||
| 15 | + | [recipe.sesh-worktrees] |
|
| 16 | + | command = "sesh worktree list -r joshmedeski/sesh --json" |
|
| 17 | + | columns = ["Title", "State"] |
|
| 18 | + | keys.enter = { run = ["sesh", "worktree", "connect", "{{.Number}}", "-r", "joshmedeski/sesh"], quit = true } |
|
| 19 | + | keys.o = ["gh", "browse", "{{.Number}}", "-R", "joshmedeski/sesh"] |
|
| 20 | + | colors = { State = { OPEN = "green", CLOSED = "red", MERGED = "magenta" } } |
|
| 21 | + | ||
| 22 | + | [recipe.calendar] |
|
| 23 | + | command = ''' |
|
| 24 | + | ical upcoming --exclude-calendar Birthdays -o json | jq 'map(. as $e | .when = ($e.start_date | fromdateiso8601 |
|
| 25 | + | | strflocaltime(if $e.all_day then "%a %b %e" else "%a %b %e %l:%M %p" end)))' |
|
| 26 | + | ''' |
|
| 27 | + | columns = ["when", "title", "calendar", "location"] |
|
| 28 | + | refresh = 300 |
|
| 29 | + | ||
| 30 | + | [recipe.upcoming] |
|
| 31 | + | command = "ical upcoming --exclude-calendar Birthdays -o json" |
|
| 32 | + | days = 3 |
|
| 33 | + | date = "start_date" |
|
| 34 | + | end = "end_date" |
|
| 35 | + | columns = ["title"] |
|
| 36 | + | refresh = 300 |
|
| 37 | + | ||
| 38 | + | [recipe.reminders] |
|
| 39 | + | command = ''' |
|
| 40 | + | remindctl show --json | jq 'sort_by(.dueDate // "~") |
|
| 41 | + | | map(.due = (if .dueDate then .dueDate | fromdateiso8601 | strflocaltime("%a %b %e") else "" end))' |
|
| 42 | + | ''' |
|
| 43 | + | columns = ["due", "title", "listName"] |
|
| 44 | + | keys = { "c" = ["remindctl", "complete", "{{.id}}"], "o" = ["remindctl", "open", "{{.id}}"] } |
|
| 45 | + | refresh = 300 |
|
| 46 | + | ||
| 47 | + | [[page]] |
|
| 48 | + | title = "Dashboard" |
|
| 49 | + | sections = [ |
|
| 50 | + | [ |
|
| 51 | + | { title = "Sessions", recipe = "sesh", command = "sesh list -t --json", columns = ["Attached", "Name", "Alerts"] }, |
|
| 52 | + | { title = "Weather", command = "curl -s 'wttr.in?0'", refresh = 300 }, |
|
| 53 | + | ], |
|
| 54 | + | [ |
|
| 55 | + | { title = "Config + Zoxide", recipe = "sesh", command = "sesh list -c -z -d --json", columns = ["Name"] }, |
|
| 56 | + | { title = "Nutiliti/nutiliti", recipe = "nutiliti-worktrees" }, |
|
| 57 | + | { title = "joshmedeski/sesh", recipe = "sesh-worktrees" }, |
|
| 58 | + | ], |
|
| 59 | + | ] |
|
| 60 | + | ||
| 61 | + | [[page]] |
|
| 62 | + | title = "Life" |
|
| 63 | + | sections = [ |
|
| 64 | + | [{ title = "Upcoming", recipe = "upcoming", fit = true }], |
|
| 65 | + | [{ title = "Calendars", recipe = "calendar" }], |
|
| 66 | + | [{ title = "Reminders", recipe = "reminders" }], |
|
| 67 | + | ] |
| 4 | 4 | 'https://github.com/echasnovski/mini.nvim', |
|
| 5 | 5 | 'https://github.com/shaunsingh/nord.nvim' |
|
| 6 | 6 | }) |
|
| 7 | - | vim.cmd.colorscheme('darkmatter') |
|
| 7 | + | vim.cmd.colorscheme('nord') |
|
| 8 | 8 | ||
| 9 | 9 | -- Mini.nvim — startup modules |
|
| 10 | 10 | local win_config = function() |
| 1 | + | [tui] |
|
| 2 | + | show_icons = true |
|
| 3 | + | show_windows = true |
|
| 4 | + | prompt = " " |
|
| 5 | + | placeholder = "Choose a session" |
|
| 6 | + | group_separator = true |
|
| 7 | + | preview = true |
|
| 8 | + | ||
| 9 | + | [icons] |
|
| 10 | + | tmux = { icon = "" } |
|
| 11 | + | config = { icon = "" } |
|
| 12 | + | zoxide = { icon = "" } |
|
| 13 | + | ||
| 14 | + | [[session]] |
|
| 15 | + | name = "dotfiles" |
|
| 16 | + | icon = "" |
|
| 17 | + | path = "~/linux-dotfiles" |
|
| 18 | + | alias = "df" |
|
| 19 | + | alias_auto_connect = true |
|
| 20 | + | ||
| 21 | + | [[session]] |
|
| 22 | + | name = "website" |
|
| 23 | + | path = "~/Developer/stevedylan.dev" |
|
| 24 | + | icon = "" |
|
| 25 | + | alias = "sd" |
|
| 26 | + | alias_auto_connect = true |
| 38 | 38 | format = '[$user ]($style)' |
|
| 39 | 39 | ||
| 40 | 40 | [character] |
|
| 41 | - | success_symbol = " [](bold white)" |
|
| 42 | - | error_symbol = " [](bold red)" |
|
| 43 | - | vimcmd_symbol = " [](bold yellow)" |
|
| 41 | + | success_symbol = " [](bold white)" |
|
| 42 | + | error_symbol = " [](bold red)" |
|
| 43 | + | vimcmd_symbol = " [](bold yellow)" |
|
| 44 | 44 | # vimcmd_replace_one_symbol = "◌" |
|
| 45 | 45 | # vimcmd_replace_symbol = "□" |
|
| 46 | 46 | # vimcmd_visual_symbol = "▼" |
| 1 | - | set -g default-terminal "xterm-256color" |
|
| 2 | - | set-option -ga terminal-overrides ",xterm-256color:Tc" |
|
| 3 | - | set -ga terminal-overrides ",xterm-256color:Tc" |
|
| 4 | - | set -g extended-keys on |
|
| 5 | - | set -g extended-keys-format csi-u |
|
| 6 | - | ||
| 7 | - | # action key |
|
| 8 | - | unbind C-b |
|
| 9 | - | set -g prefix C-q |
|
| 10 | - | set-option -g repeat-time 0 |
|
| 11 | - | ||
| 12 | - | set -g @tpm-clean 'u' |
|
| 13 | - | bind-key x kill-pane # skip "kill-pane 1? (y/n)" prompt |
|
| 14 | - | set -g detach-on-destroy off # don't exit from tmux when closing a session |
|
| 15 | - | ||
| 16 | - | # Plugins |
|
| 17 | - | set -g @tpm_plugins ' |
|
| 18 | - | tmux-plugins/tpm |
|
| 19 | - | tmux-plugins/tmux-sensible |
|
| 20 | - | christoomey/vim-tmux-navigator |
|
| 21 | - | ' |
|
| 22 | - | # set -g @plugin 'joshmedeski/t-smart-tmux-session-manager' |
|
| 23 | - | # set -g @t-fzf-prompt ' ' |
|
| 24 | - | ||
| 25 | - | # bind-key "T" display-popup -E "sesh connect \"( |
|
| 26 | - | # sesh list -i | gum filter --limit 1 --placeholder "Choose a session" --height 50 --prompt="> " --indicator.foreground="2" --match.foreground="2" |
|
| 27 | - | # )\"" |
|
| 28 | - | ||
| 29 | - | bind-key "T" run-shell "sesh connect \"$( |
|
| 30 | - | sesh list --icons --hide-duplicates | fzf-tmux --no-sort --reverse \ |
|
| 31 | - | -p 100%,100% --ansi --padding 0,1 --prompt=' ' \ |
|
| 32 | - | --border=none --input-border=rounded --preview-border=rounded \ |
|
| 33 | - | --header '^a all ^t tmux ^g configs ^x zoxide ^f find ^d kill' \ |
|
| 34 | - | --bind 'tab:down,btab:up' \ |
|
| 35 | - | --bind 'ctrl-a:reload(sesh list --icons --hide-duplicates)' \ |
|
| 36 | - | --bind 'ctrl-t:reload(sesh list -t --icons)' \ |
|
| 37 | - | --bind 'ctrl-g:reload(sesh list -c --icons)' \ |
|
| 38 | - | --bind 'ctrl-x:reload(sesh list -z --icons)' \ |
|
| 39 | - | --bind 'ctrl-f:reload(fd -H -d 2 -t d -E .Trash . ~)' \ |
|
| 40 | - | --bind 'ctrl-d:execute(tmux kill-session -t {2..})+reload(sesh list --icons --hide-duplicates)' \ |
|
| 41 | - | --preview 'sesh preview {}' --preview-window 'right:55%' \ |
|
| 42 | - | )\"" |
|
| 43 | - | ||
| 44 | - | bind-key b set-option status |
|
| 45 | - | ||
| 46 | - | set-window-option -g mode-keys vi |
|
| 47 | - | ||
| 48 | - | # turn on mouse |
|
| 49 | - | set -g mouse on |
|
| 50 | - | ||
| 51 | - | #bind t send-key C-t |
|
| 52 | - | # Reload settings |
|
| 53 | - | bind r source-file ~/.tmux.conf \; display "Reloaded!" |
|
| 54 | - | # Open current directory |
|
| 55 | - | bind o run-shell "open #{pane_current_path}" |
|
| 56 | - | bind -r e kill-pane -a |
|
| 57 | - | ||
| 58 | - | # vim-like pane switching |
|
| 59 | - | bind -r k select-pane -U |
|
| 60 | - | bind -r j select-pane -D |
|
| 61 | - | bind -r h select-pane -L |
|
| 62 | - | bind -r l select-pane -R |
|
| 63 | - | ||
| 64 | - | # Moving window |
|
| 65 | - | bind-key -n C-S-Left swap-window -t -1 \; previous-window |
|
| 66 | - | bind-key -n C-S-Right swap-window -t +1 \; next-window |
|
| 67 | - | ||
| 68 | - | # Resizing pane |
|
| 69 | - | bind -r K resize-pane -U 5 |
|
| 70 | - | bind -r J resize-pane -D 5 |
|
| 71 | - | bind -r H resize-pane -L 5 |
|
| 72 | - | bind -r L resize-pane -R 5 |
|
| 73 | - | ||
| 74 | - | # Start windows and panes at 1, not 0 |
|
| 75 | - | set -g base-index 1 |
|
| 76 | - | set -g pane-base-index 1 |
|
| 77 | - | set-window-option -g pane-base-index 1 |
|
| 78 | - | set-option -g renumber-windows on |
|
| 79 | - | ||
| 80 | - | # Opens split panes in current path |
|
| 81 | - | bind '"' split-window -v -c "#{pan_current_path}" |
|
| 82 | - | bind % split-window -h -c "#{pane_current_path}" |
|
| 83 | - | ||
| 84 | - | ||
| 85 | - | #set-option utf8-default on |
|
| 86 | - | #set-option -g mouse-select-pane |
|
| 87 | - | set-window-option -g mode-keys vi |
|
| 88 | - | #set-window-option -g utf8 on |
|
| 89 | - | # look'n feel |
|
| 90 | - | set-option -g status-position "top" |
|
| 91 | - | set-option -g status-style bg=colour0,fg=default |
|
| 92 | - | set-option -g status-justify centre |
|
| 93 | - | set-option -g status-left '#[bg=default,fg=default,bold]#{?client_prefix,, }#[bg=default,fg=colour3,bold]#{?client_prefix, ,}' |
|
| 94 | - | set-option -g status-right '#S' |
|
| 95 | - | set-option -g window-status-format '#[bg=colour0,fg=colour2] #W ' |
|
| 96 | - | set-option -g window-status-current-format '#[bg=colour0,fg=colour3] #W#{?window_zoomed_flag, , }' |
|
| 97 | - | ||
| 98 | - | ||
| 99 | - | run '~/.tmux/plugins/tpm/tpm' |
Binary file — no preview.
| 1 | + | set -g default-terminal "xterm-256color" |
|
| 2 | + | set-option -ga terminal-overrides ",xterm-256color:Tc" |
|
| 3 | + | set -ga terminal-overrides ",xterm-256color:Tc" |
|
| 4 | + | set -g extended-keys on |
|
| 5 | + | set -g extended-keys-format csi-u |
|
| 6 | + | ||
| 7 | + | # action key |
|
| 8 | + | unbind C-b |
|
| 9 | + | set -g prefix C-q |
|
| 10 | + | set-option -g repeat-time 0 |
|
| 11 | + | ||
| 12 | + | set -g @tpm-clean 'u' |
|
| 13 | + | bind-key x kill-pane # skip "kill-pane 1? (y/n)" prompt |
|
| 14 | + | set -g detach-on-destroy off # don't exit from tmux when closing a session |
|
| 15 | + | ||
| 16 | + | # Plugins |
|
| 17 | + | set -g @tpm_plugins ' |
|
| 18 | + | tmux-plugins/tpm |
|
| 19 | + | tmux-plugins/tmux-sensible |
|
| 20 | + | christoomey/vim-tmux-navigator |
|
| 21 | + | ' |
|
| 22 | + | # set -g @plugin 'joshmedeski/t-smart-tmux-session-manager' |
|
| 23 | + | # set -g @t-fzf-prompt ' ' |
|
| 24 | + | ||
| 25 | + | # bind-key "T" display-popup -E "sesh connect \"( |
|
| 26 | + | # sesh list -i | gum filter --limit 1 --placeholder "Choose a session" --height 50 --prompt="> " --indicator.foreground="2" --match.foreground="2" |
|
| 27 | + | # )\"" |
|
| 28 | + | ||
| 29 | + | bind-key "T" display-popup -B -h 100% -w 100% -E "sesh picker -Hds" |
|
| 30 | + | ||
| 31 | + | # bind-key "T" run-shell "sesh connect \"$( |
|
| 32 | + | # sesh list --icons --hide-duplicates | fzf-tmux --no-sort --reverse \ |
|
| 33 | + | # -p 100%,100% --ansi --padding 0,1 --prompt=' ' \ |
|
| 34 | + | # --border=none --input-border=rounded --preview-border=rounded \ |
|
| 35 | + | # --header '^a all ^t tmux ^g configs ^x zoxide ^f find ^d kill' \ |
|
| 36 | + | # --bind 'tab:down,btab:up' \ |
|
| 37 | + | # --bind 'ctrl-a:reload(sesh list --icons --hide-duplicates)' \ |
|
| 38 | + | # --bind 'ctrl-t:reload(sesh list -t --icons)' \ |
|
| 39 | + | # --bind 'ctrl-g:reload(sesh list -c --icons)' \ |
|
| 40 | + | # --bind 'ctrl-x:reload(sesh list -z --icons)' \ |
|
| 41 | + | # --bind 'ctrl-f:reload(fd -H -d 2 -t d -E .Trash . ~)' \ |
|
| 42 | + | # --bind 'ctrl-d:execute(tmux kill-session -t {2..})+reload(sesh list --icons --hide-duplicates)' \ |
|
| 43 | + | # --preview 'sesh preview {}' --preview-window 'right:55%' \ |
|
| 44 | + | # )\"" |
|
| 45 | + | ||
| 46 | + | bind-key b set-option status |
|
| 47 | + | ||
| 48 | + | set-window-option -g mode-keys vi |
|
| 49 | + | ||
| 50 | + | # turn on mouse |
|
| 51 | + | set -g mouse on |
|
| 52 | + | ||
| 53 | + | #bind t send-key C-t |
|
| 54 | + | # Reload settings |
|
| 55 | + | bind r source-file ~/.tmux.conf \; display "Reloaded!" |
|
| 56 | + | # Open current directory |
|
| 57 | + | bind o run-shell "open #{pane_current_path}" |
|
| 58 | + | bind -r e kill-pane -a |
|
| 59 | + | ||
| 60 | + | # vim-like pane switching |
|
| 61 | + | bind -r k select-pane -U |
|
| 62 | + | bind -r j select-pane -D |
|
| 63 | + | bind -r h select-pane -L |
|
| 64 | + | bind -r l select-pane -R |
|
| 65 | + | ||
| 66 | + | # Moving window |
|
| 67 | + | bind-key -n C-S-Left swap-window -t -1 \; previous-window |
|
| 68 | + | bind-key -n C-S-Right swap-window -t +1 \; next-window |
|
| 69 | + | ||
| 70 | + | # Resizing pane |
|
| 71 | + | bind -r K resize-pane -U 5 |
|
| 72 | + | bind -r J resize-pane -D 5 |
|
| 73 | + | bind -r H resize-pane -L 5 |
|
| 74 | + | bind -r L resize-pane -R 5 |
|
| 75 | + | ||
| 76 | + | # Start windows and panes at 1, not 0 |
|
| 77 | + | set -g base-index 1 |
|
| 78 | + | set -g pane-base-index 1 |
|
| 79 | + | set-window-option -g pane-base-index 1 |
|
| 80 | + | set-option -g renumber-windows on |
|
| 81 | + | ||
| 82 | + | # Opens split panes in current path |
|
| 83 | + | bind '"' split-window -v -c "#{pan_current_path}" |
|
| 84 | + | bind % split-window -h -c "#{pane_current_path}" |
|
| 85 | + | ||
| 86 | + | ||
| 87 | + | #set-option utf8-default on |
|
| 88 | + | #set-option -g mouse-select-pane |
|
| 89 | + | set-window-option -g mode-keys vi |
|
| 90 | + | #set-window-option -g utf8 on |
|
| 91 | + | # look'n feel |
|
| 92 | + | set-option -g status-position "top" |
|
| 93 | + | set-option -g status-style bg=colour0,fg=default |
|
| 94 | + | set-option -g status-justify centre |
|
| 95 | + | set-option -g status-left '#[bg=default,fg=default,bold]#{?client_prefix,, }#[bg=default,fg=colour3,bold]#{?client_prefix, ,}' |
|
| 96 | + | set-option -g status-right '#S' |
|
| 97 | + | set-option -g window-status-format '#[bg=colour0,fg=colour2] #W ' |
|
| 98 | + | set-option -g window-status-current-format '#[bg=colour0,fg=colour3] #W#{?window_zoomed_flag, , }' |
|
| 99 | + | ||
| 100 | + | ||
| 101 | + | run '~/.tmux/plugins/tpm/tpm' |
| 92 | 92 | ||
| 93 | 93 | path_add "/opt/homebrew/bin" |
|
| 94 | 94 | path_add "/usr/local/go/bin" |
|
| 95 | + | path_add "$HOME/go/bin" |
|
| 95 | 96 | path_add "$HOME/.cargo/bin" |
|
| 96 | 97 | path_add "$HOME/.local/share/go/bin" |
|
| 97 | 98 | path_add "$HOME/.local/bin" |
|
| 149 | 150 | alias keys='keysmasher' |
|
| 150 | 151 | alias timestamp='node -e "process.stdout.write(new Date().toISOString())"' |
|
| 151 | 152 | alias cleardns='sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder' |
|
| 153 | + | alias t='sesh picker' |
|
| 152 | 154 | ||
| 153 | 155 | # ------------------------------------------- |
|
| 154 | 156 | # Suffix Aliases - Open Files by Extension |
|
| 168 | 170 | # ============================================================================= |
|
| 169 | 171 | # Functions |
|
| 170 | 172 | # ============================================================================= |
|
| 171 | - | # Open a sesh session via gum filter |
|
| 172 | - | t() { |
|
| 173 | - | local selected |
|
| 174 | - | selected=$(sesh list -i | gum filter --limit 1 --placeholder "Choose a session" --height 50 --prompt="> " --indicator.foreground="2" --match.foreground="2") |
|
| 175 | - | if [ -z "$selected" ]; then |
|
| 176 | - | echo "No session selected" |
|
| 177 | - | else |
|
| 178 | - | sesh connect "$selected" |
|
| 179 | - | fi |
|
| 180 | - | } |
|
| 181 | 173 | ||
| 182 | 174 | # Fuzzy-find a file and open in nvim |
|
| 183 | 175 | nvimf() { |
|
| 213 | 205 | ||
| 214 | 206 | # Copy file contents to clipboard |
|
| 215 | 207 | cpf() { |
|
| 216 | - | cat "$1" | pbcopy |
|
| 208 | + | cat "$1" | wl-copy |
|
| 217 | 209 | echo "✔︎ Copied to clipboard!" |
|
| 218 | - | } |
|
| 219 | - | ||
| 220 | - | # Set orbiter key to personal |
|
| 221 | - | orbiter-personal() { |
|
| 222 | - | gum spin --spinner dot --spinner.foreground="2" --title "Updating..." -- orbiter auth --key "$(op read 'op://Personal/orbiter-api-key/credential')" |
|
| 223 | - | local check |
|
| 224 | - | check=$(gum style --foreground="2" "✓ ") |
|
| 225 | - | gum join "$check" "Orbiter key set to personal!" |
|
| 226 | - | } |
|
| 227 | - | ||
| 228 | - | # Set orbiter key to orbiter account |
|
| 229 | - | orbiter-account() { |
|
| 230 | - | gum spin --spinner dot --spinner.foreground="2" --title "Updating..." -- orbiter auth --key "$(op read 'op://Personal/orbiter-account-api-key/credential')" |
|
| 231 | - | local check |
|
| 232 | - | check=$(gum style --foreground="2" "✓ ") |
|
| 233 | - | gum join "$check" "Orbiter key set to Orbiter account!" |
|
| 234 | 210 | } |
|
| 235 | 211 | ||
| 236 | 212 | # UTC timestamp for blog frontmatter |
|