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
RubyMotionについて #mixiwwdc
Search
ainame
June 24, 2013
Programming
2
400
RubyMotionについて #mixiwwdc
WWDCに行ってきたけど内容については一切話せません @ mixi
にて発表
ainame
June 24, 2013
Tweet
Share
More Decks by ainame
See All by ainame
Swift 5.7で変わる正規表現を試してみよう
ainame
4
5.9k
iOSDC 2021 - App Store用スクリーンショットの自動生成をアラビア語対応してSwiftUIで実装してみた
ainame
0
5.5k
DNN/GPU with Ruby #rubykaigi
ainame
2
3.1k
Server Side Swift実用性評価 2017 #iosdc #b
ainame
3
4.3k
Process tons of jobs with Swift
ainame
0
1.7k
Swift on the ObjC #shibuyaswift
ainame
4
800
家族アルバムみてね 開発風景 #realm_jp
ainame
4
4k
iOSで無限バックグラウンドアップロード(に挑戦してみた話)
ainame
2
4.7k
リファクタリングとtsort
ainame
1
1.7k
Other Decks in Programming
See All in Programming
なまけものオバケたち -PHP 8.4 に入った新機能の紹介-
tanakahisateru
1
120
Recoilを剥がしている話
kirik
5
6.7k
採用事例の少ないSvelteを選んだ理由と それを正解にするためにやっていること
oekazuma
2
1k
責務を分離するための例外設計 - PHPカンファレンス 2024
kajitack
3
720
htmxって知っていますか?次世代のHTML
hiro_ghap1
0
330
KubeCon + CloudNativeCon NA 2024 Overviewat Kubernetes Meetup Tokyo #68 / amsy810_k8sjp68
masayaaoyama
0
250
42 best practices for Symfony, a decade later
tucksaun
1
180
テスト自動化失敗から再挑戦しチームにオーナーシップを委譲した話/STAC2024 macho
ma_cho29
1
1.3k
Keeping it Ruby: Why Your Product Needs a Ruby SDK - RubyWorld 2024
envek
0
190
Асинхронность неизбежна: как мы проектировали сервис уведомлений
lamodatech
0
770
tidymodelsによるtidyな生存時間解析 / Japan.R2024
dropout009
1
770
開発者とQAの越境で自動テストが増える開発プロセスを実現する
92thunder
1
180
Featured
See All Featured
Stop Working from a Prison Cell
hatefulcrawdad
267
20k
BBQ
matthewcrist
85
9.4k
Facilitating Awesome Meetings
lara
50
6.1k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
6
520
Reflections from 52 weeks, 52 projects
jeffersonlam
347
20k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
28
9.1k
StorybookのUI Testing Handbookを読んだ
zakiyama
27
5.3k
The Art of Programming - Codeland 2020
erikaheidi
53
13k
The Cost Of JavaScript in 2023
addyosmani
45
7k
GitHub's CSS Performance
jonrohan
1030
460k
Into the Great Unknown - MozCon
thekraken
33
1.5k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
8
1.2k
Transcript
RubyMotionʹ͍ͭͯ 2013-06-25 גࣜձࣾϛΫγΟ @ainame
RubyMotion
None
RubyMotionͱ RubyMotion is a revolutionary toolchain for iOS. It lets
you quickly develop and test native iOS applications for iPhone or iPad, all using the awesome Ruby language you know and love.
Warning
ຊൃදΛߦ͏@ainameiOS։ൃΛ ຊ֨తʹۀͰߦ͏͜ͱແ͘ ࠓͷ3݄ࠒ͔ΒRubyMotionΛܦ༝ͯ͠ iOS։ൃࣝΛಘͨͷΈͷएഐऀͰ͢ɻ ຊൃදObjective-CTitanium mobilePhoneGapΛ ᩫΊΔҙਤશ͍͘͟͝·ͤΜɻ ෆదͳൃݴ͕ग़ͯ͠·͏͜ͱ ͋Δ͔͠Ε·ͤΜ͕·͕ྃ͢͝ঝԼ͍͞ɻ
ࣗݾհ @ainame / Satoshi Namai גࣜձࣾϛΫγΟ - ϓϩάϥϚ झຯRubyͰձࣾͰPerlΛॻ͍͍ͯ·͢ ࠷ۙεϚϗΤϯδχΞͬΆ͕͞ग़͖ͯͨ
emacsͷ֦ு motion-mode.el ࡞ͬͯ·͢
ࠓͷ RubyMotionͱ ✔ ࣗݾհ ✔ RubyMotion vs Titanium mobile/Phone Gap
RubyMotion vs Objective-C RubyMotionʹΑΔiOS։ൃͷՄೳੑ ·ͱΊ
RubyMotion vs Titanium mobile/PhoneGap ͲͪΒObjective-CҎ֎ͰiOSΞϓϦॻ͚Δ ͦͦͪΌΜͱ͑Δͷʁ Titaniumͱ͔Phone GapͱԿ͕ҧ͏ͷʁ
RubyMotionͷ͕͜͜ҧ͏ Objective-CͷRuntime্ʹ࣮͞ΕͨRuby ϒϦοδͰͳ͍ ͍ Objective-CͱϦϯΫͰ͖Δ ࣮ફRubyMotion(@naoya_ito) ΑΓ https://speakerdeck.com/naoya/shi-jian-rubymotion
None
None
None
None
None
పఈൺֱ!! Έ ༻ݴޠ ։ൃڥ औΓר͘ ڥ Android ରԠ Ձ֨ RubyMotion
Titanium Mobile Phone Gap ωΠςΟϒ ΞϓϦ Ruby shell + editor or RubyMine(IDE) rubygems cocoapods ☓ $199 ϋΠϒϦο υΞϓϦ ΄΅ JavaScript Titanium Studio (Eclipseϕʔε) Appcelerator Platform ʢ༗ঈʣ ̋ $0 ༗ঈ൛ ͋Γ Webϕʔε ϋΠϒϦο υΞϓϦ HTML5 + JavaScript shell + editor deploy→Xcode jQueryMobile ͷ ϥΠϒϥϦ ̋ $0 ˎRubyMotionҎ֎ٸᬎௐͨͷͰෆਖ਼͔֬͠Ε·ͤΜ
ൺֱ·ͱΊ Pros ωΠςΟϒΞϓϦ CocoaPods͑Δʂʂʂʂʂʂ CocoaTouchΛͬͯΕॻ͚Δ JSΑΓΦϒδΣΫτࢦͰॻ͖͍͢ Cons Android͑ͳ͍ ࠷ॳ͔Β༗ྉ
ࠓͷ RubyMotionͱ ✔ ࣗݾհ ✔ RubyMotion vs Titanium mobile/Phone Gap
✔ RubyMotion vs Objective-C RubyMotionʹΑΔiOS։ൃͷՄೳੑ ·ͱΊ
RubyMotion vs Objective-C Θ͔Γ͘͢͢ΔͨΊ vs Objective-Cͱݴ͍·ͨ͠ πʔϧνΣΠϯͱݴޠͷൺֱਖ਼͘͠ͳ͍ XcodeʴObjective-CΛ༻͍ͨඪ४తͳ։ൃͱͷൺֱ ൺֱ߲ 1.
༻͢ΔݴޠɿRuby vs Objective-C 2. ։ൃڥ ɿShell + Editor vs Xcode 3. ҆৺ײɹɹɹɿϥΠϒϥϦαϙʔτͳͲ
Ruby vs Objective-Cͦͷ̍ Objective-CͰग़དྷΔ͜ͱRubyͰ΄΅ग़དྷΔ Rubyͷඪ४ΫϥεNSObjectΛϕʔεʹ࡞ΒΕͯΔ ऑࢀরɺϙΠϯλɺGCDઐ༻ΠϯλʔϑΣΠε͋Γ ϝϞϦཧ Objective-C: ARC, MRC
RubyMotion: ARC෩ͷಠࣗཧ Πϯελϯεมʹೖ͢ΔͱΧϯτ͞ΕΔ
Ruby vs Objective-Cͦͷ̎ ܕ͚ Objective-Cɿ੩తͳܕνΣοΫ͋Γ RubyɿϏϧυ࣌ͷνΣοΫͳ͍ ϝλϓϩάϥϛϯά Objective-CɿΠϯετϩϖΫγϣϯ, performSelector, method
swizzling RubyɿΠϯετϩϖΫγϣϯ, send, define_method, instance_eval, alias_method, ΦʔϓϯΫϥε, ԋࢉࢠ(=ϝιου)Φʔόʔϩʔυ,...
Ruby vs Objective-Cͦͷ̏ จࣈྻૢ࡞ Objective-Cɿେมͦ͏ Rubyɿڧྗͳϝιου͕๛
Ruby vs Objective-Cͦͷ̐ Ϧςϥϧදه Objective-CɿਐԽͯ͠Δʂ Rubyɿγϯϓϧ
ݴޠൺֱ·ͱΊʢྑ͍ॴʣ Objective-C ੩తͳܕνΣοΫ ʑਐԽͯ͠ྑ͘ͳͬͯΔ Ruby γϯϓϧͳϧʔϧͰϝϞϦཧͰ͖Δ CRuby༝དྷͷڧྗͳϝλϓϩɾΈࠐΈͷϝιου
Objective-Cͷ։ൃڥ Xcode ิόονϦ InterfaceBuilder / StoryBoard breakpoint / LLDB ߴ͍ͱΑ͘ฉ͖·͢
ʢ͋·Γͬͯͳ͍Ͱ͢...ʣ
RubyMotionͷ։ൃڥ ࣗ༝ʹΤσΟλબ emacsͳΒmotion-mode.elͰิͱ͔͍Ζ͍Ζग़དྷΔ RubyMineʢIDEʣͰϒϨʔΫϙΠϯτଧͯΔ γΣϧ rakeʢRuby൛makeʣͰϏϧυ Interactive DebuggerʢRubyMotionͷREPLʣ guardʢϑΝΠϧมߋݕgemʣͰࣗಈςετ ib
ͱ͍͏gemΛ͏ͱInterfaceBuilder͑Δʂ
҆৺ײ Objective-C ຊՈͷ։ൃڥ CocoaPodsͰίʔυ࠶ར༻ ࠔͬͨͱ͖ʹใଟ͍ RubyMotion ຊՈͰͳ͍ͷͷiOSͷΞοϓσʔτʹଈରԠ CocoaPodsʢRubyMotionઐ༻ͷʣRubygems͑Δ ϝΠϯ։ൃऀʹຊਓʢ@watson1978͞Μʣ
None
←WWDC։࠵தͷ 2013-06-12
҆৺ײʹ͍ͭͯͷॴײ Objective-Cͷ΄͏͕ѹతͳ҆৺ײ͋Δͱࢥ͏ RubyMotionΛ͓͏ͱͨ࣌ͦ͠ΕͳΓʹ͔ࣗΒใ ΛूΊΔྗΛ͠ͳ͍ͱ͍͚ͳ͍ ͨͩɺجຊతʹࠔͬͨΒObjective-CͷίʔυΛϕλҠ২ Ͱ͖ΔͷͰͦΜͳʹࠔΒͳ͍ ຊʹࠔͬͨΒαϙʔτ͔@watson1978͞Μʹ ࣭ͯ͠ΈΔ
ࠓͷ RubyMotionͱ ✔ ࣗݾհ ✔ RubyMotion vs Titanium mobile/Phone Gap
✔ RubyMotion vs Objective-C ✔ RubyMotionʹΑΔiOS։ൃͷՄೳੑ ·ͱΊ
RubyMotionͷՄೳੑ̍ ඇৗʹ؆ܿͳίʔυΛॻ͘͜ͱ͕ग़དྷΔ ίʔυྔ͕ݮΕϝϯςφϯείετݮΔ ࠶ར༻ੑߴ·Δ UIΛDSLͰએݴతʹίʔυΛॻ͘ελΠϧʁ ͦͷͨΊʹύϑΥʔϚϯεएׯ٘ਜ਼ʁ
NSUserDefaults
None
None
RubyMotionͷՄೳੑ̎ αʔόʔαΠυͱͷ૬ੑ͕ྑ͍ʁ Railsͱ͔Sinatraͱ͔ಉ͡ݴޠͰॻ͚Δ motion-resource gemActiveRecordͱಉ͡Α͏ͳ I/FͰRESTfulAPIͱͷ௨৴͕ॻ͚Δ RailsଆAPIΛॻͨ͘ΊͷϥΠϒϥϦ͕͍ͬͯ ΔͷͰׂͱ؆୯ʹαʔόʔॻ͚Δ
Modelఆٛ ௨৴ॲཧ
ࠓͷ RubyMotionͱ ✔ ࣗݾհ ✔ RubyMotion vs Titanium mobile/Phone Gap
✔ RubyMotion vs Objective-C ✔ RubyMotionʹΑΔiOS։ൃͷՄೳੑ ✔ ·ͱΊ
·ͱΊ RubyMotioniOS։ൃʹ͓͚ΔબࢶͷҰͭʂʂ ͍Ζ͍Ζ͋Δ͚ͲͦΕͧΕదࡐదॴʂ ίʔυ͕؆ܿʹॻ͚ΔͷͰϓϩτλΠϓ ࡞Γ͍͢ͷͰʂ ͖ͦ͜ͷͷ্खͳΕʂʂʂʂʂͰؤுΔ
ͦΜͳ͜ΜͳͰ
࡞ͬͨʂʂʂʂ Shiori Shiori is a bookmark manager for github. http://github.com/ainame/Shiori
ͬͨgem BubbleWrap ProMotion NanoStoreInMotion (NanoStore from cocoapods)
σϞ
͝ਗ਼ௌ͋Γ͕ͱ͏͍͟͝·͢
ࢀߟࢿྉ RubyMotion - Ruby for iOS and OS X http://www.rubymotion.com/
࣮ફRubyMotion // Speaker Deck https://speakerdeck.com/naoya/shi-jian-rubymotion Titanium Mobile ʙຊʹ͋ͬͨ͜Θ͍ʙ http://www.slideshare.net/haradaatsea4/titanium-mobile-16371136 PhoneGapͰֶͿϚϧνεΫϦʔϯରԠϋΠϒϦουΞϓϦ։ൃ - ୈ1ճ http://itpro.nikkeibp.co.jp/article/COLUMN/20121212/443628/ RubyMotion Metaprogramming | Clay Allsopp http://clayallsopp.com/posts/rubymotion-metaprogramming/