Vimconf.live: Why is Lua a good fit for Neovim

  Рет қаралды 36,068

TJ DeVries

TJ DeVries

Күн бұрын

Пікірлер: 46
@ameertaweel9278
@ameertaweel9278 3 жыл бұрын
I thought that Lua is a weird choice at the beginning and I really wanted to know more, very nice and informative talk, answered all my questions. Thank you!
@teej_dv
@teej_dv 3 жыл бұрын
So glad it answered your questions. Thanks for the kind comment 😁
@namesame
@namesame 3 жыл бұрын
How do you render your markdown as presentation? Thanks for the presentation, Also, what is the future of luaJIT? I believe the project is dead (in the sense that its stuck at Lua 5.1).
@teej_dv
@teej_dv 3 жыл бұрын
I use "lookatme". It's really cool! I will have to do another video about LuaJIT and explain why being compatible with Lua 5.1 is not "dead" but actually a feature :) but fear not, LuaJIT is alive and well and an excellent project.
@solomonxie5157
@solomonxie5157 3 жыл бұрын
awesome presentation with lookatme! Before I saw the command, i thought it's a legit keynote!
@ironmanlifts
@ironmanlifts 3 жыл бұрын
I'm looking forward to porting my 10,000 lines of vimscript to lua :D. I think lua makes sense if you're using algorithms or processing lots of text but how can I benefit from calling the api for mapping keys and doing simple things? I think that porting is on a case by case bases.... Unless using the lua api is way faster with mapping keys etc..than normal vimscript. I'm just using key mapping as an example, I could have said append , set, or anything else... now map function, filter, etc.., that could benefit in lua if you had alot to process.. by map I mean run a function on multiple items. map(long_list,{_,f-> do lots of stuff})
@teej_dv
@teej_dv 3 жыл бұрын
Yeah, I don't think it's worth it to just port everything over right now. Some stuff is better to wait and you probably won't get any noticeable improvement anyway
@ironmanlifts
@ironmanlifts 3 жыл бұрын
@@teej_dv True that, I'm still waiting for them to fix E117: Unknown function: getreginfo , but I understand that it's probably not priority.
@ironmanlifts
@ironmanlifts 3 жыл бұрын
@@teej_dv Yea, I opened #14581 on May 18, here it is github.com/neovim/neovim/issues/14581
@adriansrfr
@adriansrfr 2 жыл бұрын
Just think how good your vim skills will get. ;-)
@abdelazizsbaai8075
@abdelazizsbaai8075 2 жыл бұрын
cool video ! What is this tool you're using for slide shows ?
@twenty-fifth420
@twenty-fifth420 Жыл бұрын
I am learning Lua for Defold and Neovim, but it feels like a more efficient Python, my first language along with Ruby. Sometimes, Less IS more.
@diogosoares3763
@diogosoares3763 2 жыл бұрын
I am new to neovim. Is Lua better for config than vimscript? Is there any difference other than the syntax?
@Danielo515
@Danielo515 2 жыл бұрын
Better? depends on taste, but it 7s much easier to organize, easier to avoid repetitive sections and way, way easier to write complex macros and mappings. I'll let you decide
@drewad0
@drewad0 Жыл бұрын
I stopped watch at 1-indexed... Jk, still a fantastic video three years later
@threesidecreaters2572
@threesidecreaters2572 3 жыл бұрын
Which program are you using for this presentation
@teej_dv
@teej_dv 3 жыл бұрын
lookatme, it's very nice!
@ac130kz
@ac130kz 4 жыл бұрын
I hate Vimscript, I hope that I'll be able to rewrite all my configs to Lua soon
@teej_dv
@teej_dv 4 жыл бұрын
Working on it! Soon hopefully we will merge native lua autocommands (running lua functions on autocommands, instead of evaluating vimscript)
@ac130kz
@ac130kz 4 жыл бұрын
@@teej_dv nice!
@tobias-edwards
@tobias-edwards 3 жыл бұрын
Font is way too small to view this on mobile
@teej_dv
@teej_dv 3 жыл бұрын
Thanks for the feeback!
@russellchido
@russellchido 4 жыл бұрын
vim 9 to have a new language with types?! WHY?! Sounds like an absolute waste of time when you already have luajit, or even just lua.
@teej_dv
@teej_dv 4 жыл бұрын
;)
@paulosantana9607
@paulosantana9607 3 жыл бұрын
maybe that Typescript hype has got into their minds
@Ericelrojo32
@Ericelrojo32 11 ай бұрын
Why Lua is not a good choice for neovim: Neovim uses luajit not the normal lua interpreter and luajit uses version 5.1 of lua that is a version of Lua from 2006 that has not been updated for a long time is a dead project, lua as a first-class citizen lenguage means breaking the compability with multiple Vim plugins because vimscript is not going to be updated in Neovim, it is not a very portable programming language while Vim having its own language made in C is available in many more platforms, it makes configuring the Vim api more complicated and adds extra code that could be unnecessary.
@ashleydavis3318
@ashleydavis3318 11 ай бұрын
???
@heian17
@heian17 19 күн бұрын
Lol, Lua is one of the most portable programming languages, to be exact, it can run in any systems where C can be run. Tell me a place where Vim can run but Lua 5.1 can't lol. Officially, Neovim only supports Lua 5.1 and only requires it. The reason Neovim chooses LuaJIT in its release is because it is the fastest and most stable Lua runtime in the world. LuaJIT can also run C code via ffi extension. Can Vimscript run C code? Anyway, users can still compile Neovim with PUC Lua 5.1 if they'd love to. Why does Lua 5.1 need to be updated? It is already complete by syntax, I haven't seen any of its bug, meanwhile Vimscript is ... If you want new features from newer Lua versions, you can use LuaJIT by Mike Pall, or even LuaJIT 2 by Open Resty, they all have selected features from Lua 5.2, 5.3. If you want new syntax, you can use Teal (typed-Lua), Moonscript (Ruby-like), Fennel (Lisp-like) or even... Vim9script. Obviously, because the first 3 languages are transpiled to Lua, but Vim9script? Yes, because TJ wrote a Vim9script - Lua transpiler already, though it was not intended for public use, but it is open-source anyway, you can download and use it.
@Grazfather
@Grazfather 4 жыл бұрын
They really should make 'smartLua' which is 0-indexed, of course implying that whoever chose to make normal Lua 1 indexed must have been smoking crack
@alanxoc3
@alanxoc3 4 жыл бұрын
The one indexing in lua isn't that bad, it just takes some getting used to.
@Grazfather
@Grazfather 4 жыл бұрын
@@alanxoc3 It's more the principle of it. Every time I write Lua I get pissed because it was such a stupid decision.
@teej_dv
@teej_dv 4 жыл бұрын
Hm, I find that I rarely even run into the problem of it being 1-indexed. Using ipairs and table.insert, it doesn't really occur to me often that the indexing strategy is different.
@Grazfather
@Grazfather 4 жыл бұрын
@@teej_dv I think the problem is that when you want to first learn it, or don't work with it often enough for it to stick this is an obvious thing to trip up on. For these use cases, which I think are super common (since Lua is used mostly for scripting in games and such) it's just annoying enough that I get reminded about and annoyed with the stupidity every time. I am sure if i wrote Lua more often it would stop bothering me.
@asdfkjhlk34
@asdfkjhlk34 4 жыл бұрын
@@Grazfather i feel like its a minor but unsolvable problem , because if they used a 0 insexed version then it would cause even more insidious bugs for those who knew lua was 1 indexed. Lose lose
Neovim Plugin From Scratch: Markdown Presentation (Part 1)
20:19
Vimconf.live: Neovim Builtin LSP
43:24
TJ DeVries
Рет қаралды 29 М.
How to treat Acne💉
00:31
ISSEI / いっせい
Рет қаралды 108 МЛН
The Best Band 😅 #toshleh #viralshort
00:11
Toshleh
Рет қаралды 22 МЛН
She made herself an ear of corn from his marmalade candies🌽🌽🌽
00:38
Valja & Maxim Family
Рет қаралды 18 МЛН
Automatically Execute *Anything* in Nvim
11:03
TJ DeVries
Рет қаралды 76 М.
Magically format embedded languages in Neovim
17:01
TJ DeVries
Рет қаралды 47 М.
LSP in Neovim (with like 3 lines of code)
10:40
TJ DeVries
Рет қаралды 19 М.
Effective Neovim: Instant IDE
16:16
TJ DeVries
Рет қаралды 834 М.
you can just do things
2:51
TJ DeVries
Рет қаралды 3,5 М.
The Only Video You Need to Get Started with Neovim
34:00
TJ DeVries
Рет қаралды 480 М.
TakeTuesday E01: nvim-cmp
30:42
TJ DeVries
Рет қаралды 64 М.
Up And Running With Neovim + LSP
34:47
Jake Wiesler
Рет қаралды 46 М.
Mastering the Vim Language
36:20
thoughtbot
Рет қаралды 618 М.
How to treat Acne💉
00:31
ISSEI / いっせい
Рет қаралды 108 МЛН