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
490
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
Why did my proposals get rejected?
okuramasafumi
1
480
A suggestion for the future of RDoc
okuramasafumi
1
69
15 JSON serializers for Ruby
okuramasafumi
2
130
Tech Events, Should We See Them from the Outside or the Inside?
okuramasafumi
1
45
Creating gems 101
okuramasafumi
1
85
How NOT to make your DSL terrible
okuramasafumi
0
310
オブジェクトしこう
okuramasafumi
2
220
Debugging Alba
okuramasafumi
1
200
Learning Ruby
okuramasafumi
5
570
Other Decks in Programming
See All in Programming
「Chatwork」Android版アプリを 支える単体テストの現在
okuzawats
0
180
PSR-15 はあなたのための ものではない? - phpcon2024
myamagishi
0
180
menu基盤チームによるGoogle Cloudの活用事例~Application Integration, Cloud Tasks編~
yoshifumi_ishikura
0
110
Mermaid x AST x 生成AI = コードとドキュメントの完全同期への道
shibuyamizuho
1
270
AWSのLambdaで PHPを動かす選択肢
rinchoku
2
300
わたしの星のままで一番星になる ~ 出産を機にSIerからEC事業会社に転職した話 ~
kimura_m_29
0
200
create_tableをしただけなのに〜囚われのuuid編〜
daisukeshinoku
0
290
生成AIでGitHubソースコード取得して仕様書を作成
shukob
0
530
【re:Growth 2024】 Aurora DSQL をちゃんと話します!
maroon1st
0
810
今年のアップデートで振り返るCDKセキュリティのシフトレフト/2024-cdk-security-shift-left
tomoki10
0
230
20年もののレガシープロダクトに 0からPHPStanを入れるまで / phpcon2024
hirobe1999
0
820
선언형 UI에서의 상태관리
l2hyunwoo
0
200
Featured
See All Featured
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
Designing Experiences People Love
moore
138
23k
A Modern Web Designer's Workflow
chriscoyier
693
190k
Git: the NoSQL Database
bkeepers
PRO
427
64k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
59k
A Philosophy of Restraint
colly
203
16k
The Language of Interfaces
destraynor
154
24k
Bash Introduction
62gerente
609
210k
Docker and Python
trallard
42
3.1k
Building Flexible Design Systems
yeseniaperezcruz
327
38k
The Cult of Friendly URLs
andyhume
78
6.1k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
251
21k
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