Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Neovim hearts Ruby
Search
Masafumi Okura
May 13, 2022
Programming
0
530
Neovim hearts Ruby
https://fukuokarb.connpass.com/event/245647/
Masafumi Okura
May 13, 2022
Tweet
Share
More Decks by Masafumi Okura
See All by Masafumi Okura
RDoc meets YARD
okuramasafumi
1
43
Why doesn't Ruby have Boolean class?
okuramasafumi
0
9
My KaigiEffect at RubyKaigi 2025, part 1
okuramasafumi
1
49
Writing documentation can be fun with plugin system
okuramasafumi
0
200
Alba: Why, How and What's So Interesting
okuramasafumi
0
400
Why did my proposals get rejected?
okuramasafumi
1
710
A suggestion for the future of RDoc
okuramasafumi
1
390
15 JSON serializers for Ruby
okuramasafumi
2
450
Tech Events, Should We See Them from the Outside or the Inside?
okuramasafumi
1
75
Other Decks in Programming
See All in Programming
UbieのAIパートナーを支えるコンテキストエンジニアリング実践
syucream
2
680
Scale out your Claude Code ~自社専用Agentで10xする開発プロセス~
yukukotani
9
2.5k
AIレビュアーをスケールさせるには / Scaling AI Reviewers
technuma
2
220
ワープロって実は計算機で
pepepper
2
1.4k
「リーダーは意思決定する人」って本当?~ 学びを現場で活かす、リーダー4ヶ月目の試行錯誤 ~
marina1017
0
240
A Gopher's Guide to Vibe Coding
danicat
0
170
兎に角、コードレビュー
mitohato14
0
150
Introduction to Git & GitHub
latte72
0
120
Honoアップデート 2025年夏
yusukebe
1
840
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
160
サーバーサイドのビルド時間87倍高速化
plaidtech
PRO
0
440
エンジニアのための”最低限いい感じ”デザイン入門
shunshobon
0
130
Featured
See All Featured
Optimizing for Happiness
mojombo
379
70k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
30
9.6k
Stop Working from a Prison Cell
hatefulcrawdad
271
21k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
183
54k
Fantastic passwords and where to find them - at NoRuKo
philnash
51
3.4k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
53
2.9k
Code Reviewing Like a Champion
maltzj
525
40k
Faster Mobile Websites
deanohume
309
31k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
18
1.1k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
31
2.2k
Done Done
chrislema
185
16k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
26k
Transcript
Neovim :hearts: Ruby OKURA Masafumi, Fukuoka.rb 0x100 ճ LT େձ,
2022-05-11
100000000ճ։࠵ ͓ΊͰͱ͏͍͟͝·͢ʂʂʂ ʢೋਐʣ
࠷ۙͷRubyͷΛฉ͍͍ͯΔͱ
͜Μͳ͕ଟ͍Ͱ͢Ͷ • typeprof͕VSCodeʹରԠͨ͠Αʂ • SteepରԠ͍ͯ͠ΔΑʂ • σόοΨVSCode্Ͱಈ͘Αʂ
શ෦VSCode͡ΌΜʂ
ԶͨͪʢVimʣʹ໌ͳ͍…ʁ
None
Neovimͱ • VimͷϑΥʔΫ • ݱతͳػೳʹଟ͘ରԠ • VimͷϓϥάΠϯ͍͍ͩͨͦͷ··͑Δ • VimͰ͑ΔϓϥάΠϯͷվྑ൛͕LuaͰॻ͔Ε͍ͯΔ͜ͱ͕ଟ͍ •
ඇৗʹ׆ൃͳ։ൃʢຊମɾϓϥάΠϯͱʹʣ
͍͔ͭ͘ͷศརͳϓϥάΠϯΛ͝հ
neovim/nvim-lspcon fi g
neovim/nvim-lspcon fi g • LSPʢVSCodeൃͷิػೳͱ͔ʹؔ͢ΔϓϩτίϧʣΛ͏ͨΊ ʹ΄΅ඞਢ • ࣄલʹొ͞ΕͨLSPαʔόʔͰ͋ΕɺઃఆϑΝΠϧΛ1ߦॻ͚ͩ͘ ͰNeovimͰ͑ΔΑ͏ʹͳΔ •
ઌSteepରԠͷύονΛ͛ͨʢએʣ • https://github.com/neovim/nvim-lspcon fi g/pull/1842
nvim-treesitter/nvim-treesitter
nvim-treesitter/nvim-treesitter • TreeSitterͱ͍͏ύʔαʔ͕Neovim͔Β͑ΔΑ͏ʹͳΔ • ΈࠐΈͷϋΠϥΠτΑΓΧϥϑϧʹͳΔ • ࢹ֮తʹจ๏ཁૉΛѲͰ͖ΔͷͰศར • ͨͩݱঢ়ɺRubyͰTreeSitterͷΈͩͱΠϯσϯτ͕յΕΔͨΊɺ syntax༗ޮʹ͢Δඞཁ͕͋Δ
Before
After
hrsh7th/nvim-cmp
hrsh7th/nvim-cmp • ࣗಈิϓϥάΠϯͰଟҰ൪ྑ͘Ͱ͖͍ͯΔ • ιʔεΛՃ͢Δ͜ͱͰ৭ʑͳީิ͔ΒิͰ͖Δ • LSP͔Βิ͕Մೳ • ίϚϯυϥΠϯݕࡧิର •
RubyΤσΟλͷิपΓ͕ऑ͍͕ɺকདྷతʹܕϕʔεͷิ༗ ޮʹͰ͖ΔͷͩΖ͏͔
mfussenegger/nvim-dap
mfussenegger/nvim-dap • Debug Adapter Protocol ( https://microsoft.github.io/debug- adapter-protocol/ ) ͕NeovimͰಈ࡞͢ΔΑ͏ʹͳΔ
• rcarriga/nvim-dap-ui Λ͏͜ͱͰIDEͬΆ͍ϦονͳUI͑Δ • suketa/nvim-dap-ruby Λ͑debug.gemͱ࿈ܞͰ͖Δ • …͕ͣͩɺݱ࣌ͰԿΒ͔ͷཧ༝ʹΑΓ͏·͘ಈ࡞͠ͳ͍
͓·͚ʢNeovimઐ༻Ͱͳ͍ͷͰʣ
tpope/vim-rails
tpope/vim-rails • 10Ҏ্લ͔Βଘࡏ͢ΔݹయతͳVimϓϥάΠϯ • `:Emodel`ίϚϯυͳͲɺRailsͷߏΛલఏͱͨ͠ίϚϯυମܥ • લड़ͷnvim-cmpͰίϚϯυิ͕Ͱ͖Δͷ͕ڧྗͰɺ`:Emodel u`ͱ ೖྗ͢Δ͚ͩͰޙิͰUserϞσϧΛ։͘͜ͱ͕Ͱ͖Δ •
Railsͷ߹ɺ”User”Ͱ࢝·ΔϑΝΠϧ͕ଟ͍ͨΊ୯ͳΔϑΝδʔ ϑΝΠϯμʔΑΓ༗ޮͳ߹͕ଟ͍
·ͱΊ
NeovimΛRubyͷ։ൃڥͱͯ͠͏͜ͱ • దͳϓϥάΠϯΛೖΕͯઃఆ͢Εे͑Δ • ٯʹݴ͏ͱɺσϑΥϧτͷঢ়ଶͰੜ࢈ੑΛߴΊΔͷ͍͠ • հͳͷɺ࠷దͳϓϥάΠϯʑมΘ͍ͬͯΔ͜ͱ • ͞Βʹ͍͏ͱׂͱߴ֬Ͱಥવಈ࡞͠ͳ͘ͳͬͨΓ͢Δ •
VimϓϥάΠϯͷੈքʹʮϦϦʔεʯʮόʔδϣϯʯͷ֓೦͕ͳ ͍ͷͰ…
NeovimΛ͏ϝϦοτ • λʔϛφϧ͚ͩͰ։ൃ͕݁͢Δ • ๛ͳϓϥάΠϯ • ωΠςΟϒͷVimΩʔόΠϯυ
Neovim͕͍͍ͯΔਓ • ࣗͰใऩू͕Ͱ͖Δ • vim-jpͱ͍͏ίϛϡχςΟ͕͋ͬͯຊޠ͕͑ΔͷͰͰ͖Δͣ • ࣗͰൺֱɾऔࣺબͰ͖Δ • ಉ͡ػೳΛ࣋ͭϓϥάΠϯ͕ෳ͋Δ͜ͱ͕ଟ͍ •
ઃఆΛࢼߦࡨޡͰ͖Δ • READMEͷ௨Γʹͨ͠ͷʹͳΜ͔มɺͱ͔Α͋͘Δ
Neovim Ruby
pp self • ໊લɿେխ࢙ʢ͓͓͘Β·͞;Έʣ • ॴଐɿϑϦʔϥϯε • ͦͷଞɿKaigi on RailsͷνʔϑΦʔΨφΠβʔɺGrow.rbͷओ࠵ऀɺ
Albaͷ࡞ऀ • ͖ͳςΩετΤσΟλɿVim
ࢀߟ • https://github.com/okuramasafumi/dot fi les/tree/master/vim