~hedy/dotfiles

f3544eccdf728beb24a115ead1b9dc73b15c59c8 — hedy 1 year, 16 days ago 790bc93 + 5bb3803
Merge branch 'master' of git.sr.ht:~hedy/dotfiles
4 files changed, 25 insertions(+), 4 deletions(-)

M .addpath
M .config/nvim/lua/plugins/outline.lua
M .vimrc
M bin/parse_addpath
M .addpath => .addpath +0 -1
@@ 1,4 1,3 @@
local/bin
.local/bin
.doomemacs/bin
local/src/pyenv/bin

M .config/nvim/lua/plugins/outline.lua => .config/nvim/lua/plugins/outline.lua +23 -2
@@ 5,8 5,10 @@
-- https://github.com/hedyhli/outline.nvim

return {
  {
  dir = "~/projects/outline.nvim",
  enabled = vim.fn.has("nvim-0.7") == 1,
  lazy = false,
  cmd = { "Outline", "OutlineOpen" },
  keys = {
    { "<leader>tt", "<cmd>Outline<CR>", desc = "Toggle outline window" },


@@ 21,7 23,10 @@ return {
    symbol_folding = {
      -- Auto fold all but current hover
      autofold_depth = 1,
      auto_unfold_hover = true,
      auto_unfold_nodes = {
        hovered = true,
        only = 2,
      },
    },
    guides = {
      -- Keep only guides that indicate siblings that might span multiple lines (vertical)


@@ 30,15 35,28 @@ return {
        bottom = ' ',
      }
    },
    keymaps = {
      close = 'q',
      unfold_all = {},
      fold_all = {},
      fold_toggle = {'<tab>', '<space>'},
    },
    outline_window = {
      show_cursorline = true,
      position = 'left',
      show_cursorline = 'focus_in_outline',
      -- Beautiful, but not very good in indicating window focus (I don't use a
      -- statusline), plus at the time of writing preview window breaks this
      -- feature... But still beautiful nonetheless!
      hide_cursor = true,
      winhl = "OutlineDetails:LineNr,OutlineLineno:LineNr,OutlineGuides:Comment",
    },
    outline_items = {
      auto_set_cursor = false,
    },
    symbols = {
      filter = {
        lua = { 'String', 'Package', 'Constant', exclude = true },
      },
      icon_fetcher = function(k)
        local buf = vim.api.nvim_win_get_buf(require('outline').state.code_win)
        local ft = vim.api.nvim_buf_get_option(buf, "ft")


@@ 52,4 70,7 @@ return {
      icon_source = "lspkind",
    },
  },
},
  -- For testing when users from this repo reports issues.
  { "simrat39/symbols-outline.nvim", config=true },
}

M .vimrc => .vimrc +1 -0
@@ 94,6 94,7 @@ endif
" So I gave up exercising muscle memory for different leaders across neovim,
" vim, emacs evil mode...
let mapleader=" "
set number
set relativenumber
syntax on
set mouse=a " allow mouse for all

M bin/parse_addpath => bin/parse_addpath +1 -1
@@ 20,5 20,5 @@ paths="$(getpaths $file)"
if [ -f "${file}_local" ]; then
    paths="$(getpaths ${file}_local) $paths"
fi
paths="$HOME/bin $paths"
paths="$HOME/bin $HOME/local/bin $paths"
echo "$paths"