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
IRB and Reline Kaigi 2024
Search
ima1zumi
May 31, 2024
0
7
IRB and Reline Kaigi 2024
ima1zumi
May 31, 2024
Tweet
Share
More Decks by ima1zumi
See All by ima1zumi
Exploring Reline: Enhancing Command Line Usability
ima1zumi
0
6
10年物のRailsアプリにキャッチアップ!〜コードを読まずに理解したかった〜
ima1zumi
0
20
RubyKaigiの登壇者一覧ページを作った
ima1zumi
0
200
Relineのその後の生活
ima1zumi
0
160
Exploring Reline: Enhancing Command Line Usability
ima1zumi
3
13k
Reline 1分 Cooking
ima1zumi
0
21
続・mruby/cにUTF-8 を実装する
ima1zumi
1
21
UTF-8 is coming to mruby/c
ima1zumi
4
5.2k
たのしいString
ima1zumi
1
530
Featured
See All Featured
The Art of Programming - Codeland 2020
erikaheidi
52
13k
Git: the NoSQL Database
bkeepers
PRO
427
64k
Imperfection Machines: The Place of Print at Facebook
scottboms
264
13k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
665
120k
Happy Clients
brianwarren
98
6.7k
KATA
mclloyd
29
14k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
44
6.8k
Rebuilding a faster, lazier Slack
samanthasiow
79
8.7k
Building Your Own Lightsaber
phodgson
103
6.1k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
31
2.7k
No one is an island. Learnings from fostering a developers community.
thoeni
19
3k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
109
49k
Transcript
IRB and Reline Kaigi in RubyKaigi 2024 RubyKaigi 2024ࣄޙษڧձ ࢥ͍ग़͕ࢭ·Βͳ͍
2024-05-31 Mari Imaizumi @ima1zumi
Haisai • Mari Imaizumi @ima1zumi • STORES, Inc. • IRB
and Reline committer 2
3
IRB and Reline Kaigi in RubyKaigi 2024 4
IRB Reline team • @tompng / Tomoya Ishida • @st0012
/ Stan Lo • @hasumikin / Hitoshi Hasumi • @ima1zumi / Mari Imaizumi 5
IRB Reline team • IRB, Reline, ruby/yamatanooroti, etc ʹίϛοτͰ͖Δ •
ruby/ruby ʹίϛοτͰ͖ͳ͍ͷͰɺRubyίϛολʔͰͳ͍ • IRB, Reline ͷϦϦʔε͕Ͱ͖Δ 6
IRB Reline team 7
IRB Reline team • RubyίϛολʔDay 0ʹຖ։ൃऀձٞΛ͍ͯ͠Δ • IRB Reline team࣮࣭։ൃऀձٞͯ͠Δ
• ډञόʔΦϑΟγϟϧύʔςΟʔձͰ • ࠓDay 1-3ͷʹ͍Ζ͍Ζͳͱ͜ΖͰߦΘΕ͍ͯͨ 8
Α͋͘Δ࣭: StanͱͲ͏ͬͯίϛϡχέʔ γϣϯ͍ͯ͠Δͷ͔ • ӳޠ • ීஈSlackGitHubͰͷςΩετίϛϡχέʔγϣϯ • RubyKaigiͷͱ͖ର໘Ͱӳޠ •
ࢲͷӳޠྗͰࡶஊݫ͍͠ɻͰIRBRelineͷͳΜͱ͔ΪϦΪϦ͍ͭͯ ͍͚ͨΓɺ͍͍͚ͭͯͳ͔ͬͨΓ͢Δ • จ຺Ͱ͍ͩͿิ͕ޮ͍ͯͦ͏ • ӳձ͕ۤखͰίʔυͱ͍͏ڞ௨ೝ͕ࣝ͋Δͱ͍͢͠ 9
KaigiͰٞͨ͠τϐοΫͷ հ 10
ເ Γ͍ͨ͜ͱɺ͘͠ᆵ 11
Remote IRB • ಈ࡞தͷRubyϓϩηεʹIRB͔Βattach͢Δ • productionͰσόοά͢Δͷʹ͑Δ͔ • Ͳ͏ͬͯ௨৴͢ΔʁRelineͲ͏͢Δʁ • RubyKaigiޙʹ࣮Λ͍͔ͭ͘ݟ͚ͭͨ
• https://github.com/QWYNG/irb-remote (druby) • https://mametter.hatenablog.com/entry/20070527/p1 (Unix socket) 12
repl_type_completorΛσϑΥϧτʹ͍ͨ͠ • IRBͷิΛܕิʹ͢ΔϥΠϒϥϦ • σϑΥϧτਖ਼نදݱͰิରΛग़͍ͯ͠ΔͷͰਫ਼͕ѱ͍ • repl_type_completorΛσϑΥϧτʹ͍ͨ͠ • ར༻࣮͕͋Δͱਪન͍͢͠ •
ಛʹೖΕΔσϝϦοτͳ͍ • /sig ʹRBSϑΝΠϧ͕େྔʹ͋ΔͱIRBͷىಈ͕͘ͳΔ͔ • Πϯετʔϧ&ઃఆํ๏ • IRBͷܕิΛ༗ޮʹ͢Δํ๏ - Eggshell https://imaizumimr.hatenablog.com/entry/2023/11/22/232624 13
yamatanooroti͕͍ • ͚ςεςΟϯάϑϨʔϜϫʔΫ • E2EςετͷΑ͏ͳͷ • ruby/yamatanooroti is forked from
aycabta/yamatanooroti • sleep 0.1 Ͱग़ྗΛ͍ͬͯΔ͔Β͍ • ϦτϥΠ͕΄͍͠ 14
·ͱΊ • ·ͩ·ͩເ͕͍ͬͺ͍͋Δ • खͬͯΒ͑Δͱ͋Γ͕͍ͨ • ͜Μͳ͜ͱ͕ΕͨΒ͍͍ͳɺͱ͍͏ϑΟʔυόοΫͱͯॿ͔Γ ·͢ • ࿓Լձٞͱָ͍ͯ͠
15
Appendix 16
ฤूίϚϯυͷϦϑΝΫλϦϯά͍ͨ͠ • ઃఆ `beginning-of-line` ͕ͩݺΕΔϝιου `beginning_of_line` • alias_method࿙Ε͕ͱ͖Ͳ͖͋Δ • ίʔυத͔ΒݺΕͯͳ͍͔ΒෆཁϝιουΈ͍ͨʹݟ͑Δ
17
ed_quoted_insert͕࣮ݱͰ͖ͳ͍ • ೖྗͨ͠จࣈΛͦͷ··ߦʹՃ͢Δػೳ • C-aΛೖྗͨ͠Βߦ಄ҠಈͰͳ͘^Aͱೖྗ͞ΕΔ • ͍·ͷRelineͰΩʔೖྗͰಛఆͷঢ়ଶʹભҠͤ͞Δͷ͍͠ • bracketed_paste_startΈ͍ͨʹ௨ৗͷॲཧ͕Βͳ͍Α͏ʹ͢ΕΑ ͦ͞͏
18