veganism.social is one of the many independent Mastodon servers you can use to participate in the fediverse.
Veganism Social is a welcoming space on the internet for vegans to connect and engage with the broader decentralized social media community.

Administered by:

Server stats:

283
active users

#neovim

17 posts16 participants0 posts today

In #Vim (and #Neovim), you can use "gf" to open the file under the cursor for editing.

However, this only works if that file already exists.

If it doesn't, and you want to open it as a new, empty file for editing, you can use ":e <cfile>" instead.

(see :h <cfile>)

TIL: on Windows, #Neovide can be tweaked with the following autocmd to ensure the title bar matches the colorscheme background. 😎

local function set_titlebar_color()
vim.g.neovide_title_background_color =
string.format("%x", vim.api.nvim_get_hl(0, {
id = vim.api.nvim_get_hl_id_by_name("Normal")
}).bg)
end
vim.api.nvim_create_autocmd({ "ColorScheme" }, {
pattern = { "*" },
callback = set_titlebar_color,
})
set_titlebar_color()

You can judge me but I am trying to move stuff from my emacs-config for orgmode (lisp-functions, capture templates) to work with neovim-orgmode. And AI-slopping it works pretty well. I am not sure yet though, how well neovim-orgmode will work out in my daily use of it. #orgmode #emacs #neovim

For those using both vim/neovim and Grafana Alloy, I've spent some time on the syntax highlighting plugin which may be useful to you:
https://github.com/jessebot/vim-alloy

It's a fork of grafana/vim-alloy and I did my best to contribute a PR as well, but the repo doesn't seem to have been touched in over a year. Hopefully others can make use of it though. Here's an example using the spacechalk theme.

:neovim: :heart_cyber: :grafana_alloy:

🌘 舊 ThinkPad 上的 Neovim 緩衝區:打造極簡網站伺服器
➤ 顛覆想像,舊筆電與 Neovim 的性能結合
vim.gabornyeki.com/
這篇文章介紹了作者如何利用 Neovim 的 Lua API 創建一個名為 `nvim-web-server` 的外掛程式,該外掛程式能夠直接從 Neovim 的開啟緩衝區提供 HTTP 請求。作者深入探討了其速度優勢,將其與 Nginx 和 Python 的 aiohttp 進行了效能比較,並歸因於 LuaJIT 的高效能以及 Neovim 對 libuv 的運用。文章同時也描述瞭如何在一部老舊的 ThinkPad 筆記型電腦上部署這個網站,展現了舊硬體仍具備實用價值的觀點。
+ 沒想到 editor 也能做這麼多事!這想法太酷了,而且還比 Nginx 快,真是讓人驚艷。
+ 這不是在開玩笑吧?用 Neovim 跑網站伺服器,而且還這麼有效率?作者真是個技術狂人!
#網站開發 #Neovim #Lua #舊硬體 #伺服器

vim.gabornyeki.comThis Website is Served from Nine Neovim Buffers on My Old ThinkPadThis Website is Served from Nine Neovim Buffers on My Old ThinkPad, a blog post by Gábor Nyéki

“I wrote a #Neovim plugin in #Lua that serves HTTP requests from open buffers. It has no external dependencies, it has first-class support for serving content in Djot, and it is faster than Nginx so it won’t be a performance bottleneck behind a reverse proxy. What’s not to like?” vim.gabornyeki.com/

vim.gabornyeki.comThis Website is Served from Nine Neovim Buffers on My Old ThinkPadThis Website is Served from Nine Neovim Buffers on My Old ThinkPad, a blog post by Gábor Nyéki

Oh wow, a website served from #Neovim #buffers on a relic ThinkPad! 🚀 Because who needs cutting-edge server tech when you can cobble together a shameless hipster project with #Lua and #Djot faster than Nginx, right? 😂 Apparently, turning text editors into web servers is the new cool—move over, actual web developers. 🔧💻
vim.gabornyeki.com/ #ThinkPad #HipsterProject #HackerNews #ngated

vim.gabornyeki.comThis Website is Served from Nine Neovim Buffers on My Old ThinkPadThis Website is Served from Nine Neovim Buffers on My Old ThinkPad, a blog post by Gábor Nyéki

Bon je galère avec Neovim, j'ai besoin de votre aide.

J'ai treesitter et treesitter-textobjects.

J'essaye de réindenter un fichier .vue. Il y a donc un mélange de HTML, JavaScript et SCSS. Pour HTML et JS ça s'indente correctement, pas d'erreur dans l'arbre des noeuds.

En revanche, le SCSS ne s'indente pas bien. Il y a des ERROR dans l'arbre de TreeSitter. Après avoir joué un peu avec, j'ai l'impression que ça bug à cause de :has et de @\extend.

Avez-vous une idée pour m'aider à résoudre mon problème ?

Edit : j'ai aussi vue-language-server en LSP.

Merci par avance. Svp retoots 🙏

#Neovim#Vim#Dev