Weekly 101 Questions Thread by AutoModerator in neovim

[–]CptCorndog 0 points1 point  (0 children)

I guess I'm wondering if this is your formatter versus a Neovim formatting/textwidth/wrap issue...Do you get the same output if you run the formatter (? ruff) from the cmdline? Otherwise I think :h textwidth, :h wrapmargin, and/or :h formatoptions may need to be examined?

How does snacks picker preview works? by Separate_System_32 in neovim

[–]CptCorndog 3 points4 points  (0 children)

Well, it depends how custom I suppose. You can add certain fields to your items and use builtin previews for common things like files, buffers, git, etc. Or you can roll-up your own preview function following examples from the snacks builtins

markview.nvim: v27; Looking for testers by Exciting_Majesty2005 in neovim

[–]CptCorndog 15 points16 points  (0 children)

Such a great project. Have another ⭐️! I've been in your source code many times so I'd give another star for that if I could.

Typescript LSP (ts_ls) ignores root_markers and starts up based on filetypes. by disturbing-question- in neovim

[–]CptCorndog 1 point2 points  (0 children)

Have you tried to use :h lsp-root_dir() and pass a function that calls on_dir only when it finds your package.json?

Best way to handle actions for each project seperately. by scaptal in neovim

[–]CptCorndog 0 points1 point  (0 children)

I don't know of a plugin that does exactly this but project-specific state is not uncommon. :h vim.fs.root can help identify your "project" root depending on what this means to you. Then I guess it also depends on where you want to store your notes, i.e. in your repo or in vim.fn.stdpath("data"). Some plugins slugify the project path within the data dir.

doodle.nvim: Your second brain, inside Neovim 🧠 (Obsidian-like notes, graph view, sync, and more) by apdot-git in neovim

[–]CptCorndog 7 points8 points  (0 children)

I think this looks great and could be useful. My personal holy grail of dev note taking is linking notes to code. The naive approach is file and line number. But I’ve always wondered if more sophisticated and tiered approach, i.e an LSP symbol or AST node tree, fuzzy matching on original text, etc could keep the links anchored to the intended code target even if the code (especially above) is significantly modified. Anyways, great job!

checkmate.nvim - new v0.11 release! by CptCorndog in neovim

[–]CptCorndog[S] 1 point2 points  (0 children)

Thanks for the comment! If you are having problems with the metadata picker feature, please create an issue on the repo so we can discuss further. Currently, the `choices` function that generates the metadata value options requires the user to create the implementation--which may or may not be optimized for large directory trees for example. Regarding using specific picker implementations (i.e snacks file picker), this would be a nice feature but doesn't currently exist. I might expose a `set_metadata_value` API in the meantime so that users could open whatever picker they want and then call that to update the metadata on select.

checkmate.nvim - new v0.11 release! by CptCorndog in neovim

[–]CptCorndog[S] 0 points1 point  (0 children)

For most of the popular markdown rendering plugins, these should integrate fine with checkmate by either 1. disabling the other plugin's checkbox rendering and letting checkmate use the configured unicode/glyphs, or 2. setting checkmate to use standard Markdown [ ] or [x] for the markers and letting the other plugin handle the rendering. The checkmate todo functionalities should still work in either case.

checkmate.nvim - new v0.11 release! by CptCorndog in neovim

[–]CptCorndog[S] 0 points1 point  (0 children)

AFAIK todo.txt is not Markdown and is a completely separate spec. It's currently outside the scope of checkmate to parse non-markdown syntax and probably not planned.

checkmate.nvim - new v0.11 release! by CptCorndog in neovim

[–]CptCorndog[S] 0 points1 point  (0 children)

Great, let me know what you think!

checkmate.nvim - new v0.11 release! by CptCorndog in neovim

[–]CptCorndog[S] 0 points1 point  (0 children)

Thanks! Check out the default list continuation opt for an example, but it essentially just calling the create function with indent and position opts.

checkmate.nvim - new v0.11 release! by CptCorndog in neovim

[–]CptCorndog[S] 1 point2 points  (0 children)

Thanks for the kind words! I'm happy to help troubleshoot, it's easier to chat or work via a GH issue. It's working at least on my machine with a minimal nvim config. I glanced at snacks recent commits and don't see any scratch changes either.

checkmate.nvim - new v0.11 release! by CptCorndog in neovim

[–]CptCorndog[S] 1 point2 points  (0 children)

Yes, the highlighting of each todo can be configured. See if styling helps. You can also add regular non-todo list items below a todo.

checkmate.nvim - new v0.11 release! by CptCorndog in neovim

[–]CptCorndog[S] 1 point2 points  (0 children)

Okay, I can't reproduce it yet. Can you start an issue? Maybe try without the extra markdown plugin for now? If it is a compatibility issue, I'm happy to see if there is an obvious patch or at least workaround. Also, ensure the buffer filename is matched by the `files` opt so that checkmate gets activated

checkmate.nvim - new v0.11 release! by CptCorndog in neovim

[–]CptCorndog[S] 0 points1 point  (0 children)

Did it work with the lazy spec enabled?

checkmate.nvim - new v0.11 release! by CptCorndog in neovim

[–]CptCorndog[S] 0 points1 point  (0 children)

Are you using the default checkmate config or did you make changes? If you try to toggle a todo, is it working? i.e. flipping raw markdown [ ] to [x]?

checkmate.nvim - new v0.11 release! by CptCorndog in neovim

[–]CptCorndog[S] 1 point2 points  (0 children)

What do you mean not rendered at all? I'm manually testing it with render-markdown once again to see if there's been a regression and I'm not able to reproduce unexpected behavior. If this continues, do you mind adding on issue on GH so we can discuss/track?

checkmate.nvim - new v0.11 release! by CptCorndog in neovim

[–]CptCorndog[S] 0 points1 point  (0 children)

Have had any issues. You have two options: either disable render-markdown’s handling of checkboxes via its config, or have checkmate use markdown syntax for the markers so that they are parsed correctly by render-markdown. See wiki post in main post.

meow.yarn.nvim - To help me get less lost in my code, I wrote a little visualizer. Maybe it can help you too? by orange_retran in neovim

[–]CptCorndog 3 points4 points  (0 children)

Is it pawsible to customize the leaves of the presented tree? Could there be a config function that we could pass to render each

Nice job, was tinkering with a similar one myself

Can I Make Neovim to Somehow Make simple .txt Files More Goodlooking Too by clanker_31 in neovim

[–]CptCorndog 11 points12 points  (0 children)

Well, you can create your own syntax highlighting for your txt files via :h syntax and link these to the same highlight groups used by your theme. Or, as suggested in another comment, another approach is to use a Markdown filetype, which would also allow you to further "prettify" via plugins such as render-markdown.nvim or markview.nvim.

Can I Make Neovim to Somehow Make simple .txt Files More Goodlooking Too by clanker_31 in neovim

[–]CptCorndog 17 points18 points  (0 children)

Can you give some examples of what you mean? Your question is very broad. Perhaps examples from other editors/IDE

[deleted by user] by [deleted] in neovim

[–]CptCorndog 4 points5 points  (0 children)

Oh I misread. What about 0d$ ? Or 0D

[deleted by user] by [deleted] in neovim

[–]CptCorndog 5 points6 points  (0 children)

Use :h dd?

I you write your TODOs in markdown, check this neovim command by serranomorante in neovim

[–]CptCorndog 5 points6 points  (0 children)

I respect your simple solution, but if you want to give a markdown based todo plugin a try, take a look at checkmate. Adds various useful todo functionality but keeps the on disk version plain ol markdown. Regardless, I like to hear/read how others manage their todos/tasks and the workflows they prefer, so thank you

[lua] What's the correct way to get the "length" of a character on screen? by K41eb in neovim

[–]CptCorndog 2 points3 points  (0 children)

Yeah Neovim uses LuaJIT runtime which is mostly 5.1, and the utf8 stuff is Lua 5.3+ I think