26
17

Seems like TWIN's site (https://this-week-in-neovim.org/) is down - the dns doesn't resolve.

IIRC the author was moving away from neovim and was having some maintainence issues, but I'm curious if anyone else has more info ^.^?

27
98
submitted 11 months ago* (last edited 11 months ago) by ck_@discuss.tchncs.de to c/neovim@sopuli.xyz
28
15
Neovim 💚 Fennel! (git.minimally.online)
submitted 11 months ago* (last edited 3 months ago) by specter@board.minimally.online to c/neovim@sopuli.xyz

cross-posted from: https://board.minimally.online/post/20318

I just recently discovered TIC-80 and then Fennel. I was already liking Lua but now I'm hooked on LISP!! Here's my Neovim config using lazy.nvim, all written in fennel thanks to hotpot

It's not marketed like one of those "template Neovim config repos" but it could be one of those if your heart desired. I based it loosely off kickstart.nvim.

29
10
submitted 11 months ago* (last edited 11 months ago) by p00f@hachyderm.io to c/neovim@sopuli.xyz

clangd-extensions.nvim (https://git.sr.ht/~p00f/clangd_extensions.nvim) now has go-to-defintion in the type hierarchy window

@VimLinks @neovim

30
6
submitted 11 months ago by pipoprods@lemmy.ml to c/neovim@sopuli.xyz

I'm using Nightfox theme and treesitter parser for syntax highlight.

My code blocks in markdown files get displayed in italic, which is quite unreadable…

How could I configure nvim to displayed them as normal characters?

31
44
This week in Neovim (dotfyle.com)
submitted 11 months ago by mrmanager to c/neovim@sopuli.xyz

Just sharing this on Lemmy as well for all you amazing neovim users. :)

32
3
submitted 11 months ago by _calm_bomb_@lemmy.ml to c/neovim@sopuli.xyz

So, I've been using nvim on macos for almost two months and didn't have issues, but after the last update I'm seeing this:

Error detected while processing BufReadPost Autocommands for "*":
Error executing lua callback: ...ocal/Cellar/neovim/0.9.1/share/nvim/runtime/filetype.lua:21: Error executing lua: ...ocal/Cellar/neovim/0.9.1/shar
e/nvim/runtime/filetype.lua:22: BufReadPost Autocommands for "*"..FileType Autocommands for "*": Vim(append):Error executing lua callback: vim/load
er.lua:0: EACCES: permission denied: /Users/clmbmb/.cache/nvim/luac/%Users%clmbmb%.local%share%nvim%lazy%null-ls.nvim%lua%null-ls%rpc.luac
...

This happens (for now) only when trying to open .lua files.

From what I gather there's something related to some filesystem security flags in macos. I'm new to macos, so I have no idea what happens.

Any hints/solutions to this?

33
11
submitted 11 months ago by rjooske@lemmy.world to c/neovim@sopuli.xyz

Is there a way to avoid opening a nested neovim instance inside a terminal buffer and instead open it as a new buffer inside the already running instance? I'm thinking something like what Fugitive does, but more general and that works for any shell commands.

34
3
submitted 11 months ago* (last edited 11 months ago) by CjkOvPDwQW@lemmy.pt to c/neovim@sopuli.xyz

Hi everyone long time vim/neovim user, currently for my latex I have in ~/.config/nvim/after/ftplugin.lua the following line:

vim.opt_local.makeprg="pdflatex -output-format pdf -output-directory /tmp %"

I am now working in a latex project that has a makefile, is it possible to create something in the lines of:

if ! makefile_exists then
  vim.opt_local.makeprg="pdflatex -output-format pdf -output-directory /tmp %"
end

Ended up with this and it seems to work fine:

~/.config/nvim/after/ftplugin/tex.lua

local makefile_exists = vim.fs.find('makefile', {
  upward = true,
  stop = vim.uv.os_homedir(),
  path = vim.fs.dirname(vim.api.nvim_buf_get_name(0)),
})

if #makefile_exists == 0 then
	vim.opt_local.makeprg = "pdflatex -output-format pdf -output-directory /tmp %"
end
35
3
submitted 11 months ago* (last edited 11 months ago) by Agility0971@lemmy.world to c/neovim@sopuli.xyz

I'm using NvChad and in ~/.config/nvim/lua/core/mappings.lua there is a keybinding for LSP code action:

  ["<leader>ca"] = {
    function()
      vim.lsp.buf.code_action()
      -- TODO: write buffer to file
    end,
    "LSP code action",
},

this keybinding applies the code action, but does not write to file. I want to write changes to file as soon as I've applied the code action.

How can I use the documentation at https://neovim.io/doc/ to find the correct function? I've tried looking for a write() function but I could not find anything I can call from lua.

36
19
TWiN is back (dotfyle.com)
submitted 11 months ago by doomkernel@sopuli.xyz to c/neovim@sopuli.xyz

We got TWiN back! No RSS for now but good to see someone stepping in and keep to project alive.

37
26
submitted 1 year ago by dlanm2u@sopuli.xyz to c/neovim@sopuli.xyz

out of curiousity, since I feel like most of the time I touch any vi derivative it’s because I need a text editor on a command line, not because I really really wanna use it

38
38
submitted 1 year ago by ck_@discuss.tchncs.de to c/neovim@sopuli.xyz
39
12
submitted 1 year ago* (last edited 1 year ago) by may_pretender@feddit.ro to c/neovim@sopuli.xyz

So, I've been a Neovim user for a few years now. I started as most of you (I assume) with vim, and just kept on using and expanding that config file over the years.

I only recently realized there's quite a split between the Vim and Neovim plugins and that the Neovim community is pushing Lua as a better development platform. From what I can see, some users are switching their configs from Vimscript to Lua. To be honest all I know about Lua is that it means moon in Portuguese...

Should I too? What would the advantages be? What would the disadvantages be? For those who did switch, why did you switch and what was your experience? For those who didn't why did you not?

p.s. review (roast) my dotfiles

edit: thank you all for your input! I will consider slowly switching to lua by modifying only some parts of the config as some of you suggested.

40
7
submitted 1 year ago by dlvhdr@lemmy.world to c/neovim@sopuli.xyz

I’ve tried all the surround plugins but what I really want is just the simple flow of: make a selection -> press “, ( etc to surround. Is that not possible with vim?

41
6
submitted 1 year ago by mawkler@lemmy.ml to c/neovim@sopuli.xyz

I saw that null-ls.nvim just added textidote support. Textidote seems to be a spelling/grammar checker that wraps LanguageTool, just like ltex-ls. Does anyone know how they compare?

42
7
submitted 1 year ago by Chocrates@lemmy.world to c/neovim@sopuli.xyz

I am rewriting my ancient vim config into Lua with nvim. I am using Mason to grab lsp language servers and for the most part it works great!

I have this in my remaps so I can <leader>f to format the current file (still need to figure out formatting on save too, but I can't for the life of me get Markdown formatting working.

vim.keymap.set("n", "<leader>f", function()
	vim.lsp.buf.format()
end)

I have markdownlint, marksman, prettier, and prettierd all installed wth Mason (though I haven't written any keymaps or configs for them). Any idea how I can format my Markdown? I write in it all day every day so it's gonna help a ton if I can get it working. Secondly any ideas how I can do the same mapping for the formatting on save? Still pretty new to Lua.

43
11

Hey guys, I'm following the tutorial above, and in his video he doesn't do anything specific to show hidden files, but it works for him. My .config/nvim/after/plugin/telescope.lua file looks like this: I've looked up solutions but they all use a different syntax, and none work for me. Any idea how I can make the find_files command also show hidden files by using this syntax? Thanks!

44
12
submitted 1 year ago by siipale@sopuli.xyz to c/neovim@sopuli.xyz

This is a very simple thing but it can be useful for folks who are still using mostly arrow keys. It finally clicked for me when I started using Tridactyl for Firefox :)

Most of the time you need down and up motions so you rest your index finger on J and middle finger on K. J looks little bit like a down arrow (mnemonics jown and kup don't seem very intuitive to me). So now you have the main arrow keys assigned to your fingers. Naturally you rest your ring finger on the L key and when you occasionally need to move left just move your index finger to the H key.

45
3

Hello !

In my day to day work I often have to write small snippets to illustrate ticket tech strategy.

I was wondering if you guys knew a cool way to have quick scratchpad where I could manipulate the snippet, format it, and have minimal syntax coloration.

This is usually handled by LSP, but sometimes having a full lsp running is not practical, with all the overhead of typescript config for example.

Main formats are JSON, typescript and soon Rust.

Cheers

46
6
submitted 1 year ago* (last edited 1 year ago) by noornee@lemmy.ml to c/neovim@sopuli.xyz

i currently use Iosevka Nerd Font.

the cancel icon (X) looks too big and i want to change it to lowercase (x). i looked through the nvim-web-devicons readme and i also tried printing out all the available icons there

i.e.

local devicons = require("nvim-web-devicons").get_icons()
for _, value in pairs(devicons) do
	for i, v in pairs(value) do
		print(i .. "==>" .. v .. "\n")
	end
end

but i couldnt find an icon with a name that matches X or cancel. what can i do to override this and replace with a custom one?

[edit] i use barbar.nvim for buffers btw.

i just tried akinsho/bufferline and the cancel icon looked normal. i suppose this is a barbar issue

[edit]:

okay turns out it was a barbar issue. just had to read through the README.md properly haha.

M.config = function()
	require("barbar").setup({
		icons = {
			button = "x", -- customize it to anything 
		},
	})
end

47
3
submitted 1 year ago by Nico792@lemmy.ml to c/neovim@sopuli.xyz

Hi, I’m new to neovim so there’s a decent chance this is just a rookie mistake. I wanted to make an autocmd to remap F5 to running the (python) file. I found a stack overflow post on how to do this (https://stackoverflow.com/questions/18948491/running-python-code-in-vim ) but that was for vim. I tried my best to translate if for neovim using some other tutorials I found (and doing my best at understanding docs), what I came up with is this:

local api = vim.api
local RunFile = api.nvim_create_augroup("RunFile", { clear = true })

api.nvim_create_autocmd(
    "FileType",
    {
        callback = "map <buffer> <F5> :w<cr>:exec '!python3' shellescape(@%, 1)<cr>",
        pattern = "python",
        group = RunFile,
    }
)

however when I include the file in my init.lua, not only does it not work (the autocmd doesn’t even show up when looking in :au FileType, let alone run) it also makes the text a boring white and when I try to format, it gives the error [LSP] Format request failed, no matching language servers. while I definitely do have the language server (it works when the autocmd file is not included in init.lua). I’m probably just making some simple mistakes, but I cannot for the life of me find what I’m doing wrong. Does anyone here have any suggestions? For the record, I use lsp zero and treesitter

48
6
Shitpost (lemmy.world)
submitted 1 year ago by santos@lemmy.world to c/neovim@sopuli.xyz
49
12
submitted 1 year ago* (last edited 1 year ago) by sorrybookbroke@sh.itjust.works to c/neovim@sopuli.xyz

Zeioth has created a fantastic plugin for those of you looking to make Neovim more like an IDE. Run the open command, tell it to build, have it compile, execute, and output your code in a really nice looking way all inside neovim.

It's still pretty early but this is looking promising. It's already very customizable with support for a few languages, with more in the works.

Give it a look: https://github.com/Zeioth/Compiler.nvim

50
26
submitted 1 year ago by yads@lemmy.world to c/neovim@sopuli.xyz

I've been absolutely loving treesitter. It's come a long way and it's been absolutely great for things like folds, motions, highlights of course. Now that I've finally gotten familiar with writing my own queries I can extend the existing plugins. As an example I've added folds to blocks of multiple consecutive comments in JS and Ruby.

What are some of your favorites?

view more: ‹ prev next ›

Neovim

1604 readers
1 users here now

Neovim is a modal text editor forked off of Vim in 2014. Being modal means that you do not simply type text on screen, but the behavior and functionality of the editor changes entirely depending on the mode.

The most common and most used mode, the "normal mode" for Neovim is to essentially turn your keyboard in to hotkeys with which you can navigate and manipulate text. Several modes exist, but two other most common ones are "insert mode" where you type in text directly as if it was a traditional text editor, and "visual mode" where you select text.

Neovim seeks to enable further community participation in its development and to make drastic changes without turning it in to something that is "not Vim". Neovim also seeks to enable embedding the editor within GUI applications.

The Neovim logo by Jason Long is licensed under the Creative Commons Attribution 3.0 Unported License.

founded 3 years ago
MODERATORS