Upgrade to Pro — share decks privately, control downloads, hide ads and more …

18年でRubyから学んだこと - 関西Ruby会議 2017

Yuichiro MASUI
May 28, 2017
2.1k

18年でRubyから学んだこと - 関西Ruby会議 2017

Yuichiro MASUI

May 28, 2017
Tweet

Transcript

  1. 18೥Ͱ
    Ruby͔ΒֶΜͩ͜ͱ
    Yuichiro MASUI

    View full-size slide

  2. @masuidrive
    Yuichiro MASUI
    Toreta, Inc. CTO

    View full-size slide

  3. ෩࿊άϥϚʔ

    View full-size slide

  4. Rubyྺ 18೥͙Β͍
    • ͨͿΜ1999೥͙Β͍͔Β࢖ͬͯΔ
    • PHP/FI͸1997೥͔Β
    • ͦͷલ͸Perl, C, C++

    View full-size slide

  5. Ruby
    • Ͳ͜Ͱݟ͚ͭͨͷ͔֮͑ͯͳ͍
    • ݩʑݴޠεΩʔͰ৭ʑͳݴޠΛࢼ͍ͯͨ͠͸ͣ
    • ΦϒδΣΫτࢦ޲Λखܰʹ࢖͑Δ
    • ΠϯλϓϦλͰ৭ʑࢼͤΔ
    • ೔ຊޠͰҰ࣍৘ใ͕͋Δ

    View full-size slide

  6. method_missing
    • Ұ൪޷͖ͳϝιου
    • ͳΜͰ΋ΞϦ
    • ݪҼෆ໌ͳڍಈͷݩڟ
    • ιʔεΛ௥͏ͷΛ΄΅ෆՄೳʹ͢Δ
    • ࣍͸ define_method

    View full-size slide

  7. dRuby
    • Java / RMIͱ͔ʹϋϚͬͯͨ
    • ෼ࢄΦϒδΣΫτͱ͔ਥೋతʹ͓͍͍͠
    • ιʔείʔυΊͬͪΌ୹͍

    View full-size slide

  8. ͣʔͬͱϢʔβ
    • Rubyຊମʹ͸ίϛοτ΋ͤͣ
    • ϝʔϦϯάϦετ΋1-2ճ࣭໰͚ͨͩ͠
    • ίϛϡχςΟʔ׆ಈ΋ͳ͠
    • Gem΋Ұݸ͚ͩ

    View full-size slide

  9. ਺গͳ͍ߩݙ

    View full-size slide

  10. 1999೥
    • i-mode
    • PHP, PostgreSQL
    • ݸਓతʹ͸ FreeBSD > Linux
    • ADSLҎલ (Y! BB͸2001೥)

    View full-size slide

  11. ౰࣌ͷRubyͷ࢖͍ಓ
    • ศརͳone liner (awkͷ୅ΘΓͱ͔)
    • ςΩετ΍CSVԽͨ͠σʔλϕʔεͷલॲཧ
    • ूܭॲཧ

    View full-size slide

  12. ΦϒδΣΫτࢦ޲
    • ΄ͱΜͲRuby͔Β֮͑ͨ
    • Ϋϥεϕʔε͚ͩͲߴ͍ॊೈੑ
    • ଟ༷ͳϥΠϒϥϦͱαϯϓϧ

    View full-size slide

  13. RubyʹڭΘͬͨ͜ͱ
    • ΠςϨʔλ
    • Ϋϩʔδϟ
    • ϝλϓϩάϥϛϯά
    • Ϣχοτςετ

    View full-size slide

  14. 2000೥୅લ൒
    • PHPͰPukiWiki࡞ͬͯͨ
    • ىۀͯ͠i-modeͷαΠτߏங
    • Linux World΍Linux MagazineͰࣥච
    • Ajaxؔ܎ͷهࣄ΍ຊΛࣥච

    View full-size slide

  15. WindowsͰ΋ؤுͬͯͨ
    • wxWindowsͱ͔QT࢖ͬͯGUIΞϓϦ࡞Γ
    • exerb࢖ͬͯύοέʔδϯά
    • ActiveScript Ruby

    View full-size slide

  16. Ruby on Rails
    • 2004/07 - DHH͕ެ։
    • 2005೥಄͙Β͍ʹൃݟ
    • ͍͢͝ʂRubyͰWebΞϓϦ͕ΩϨΠʹ࡞ΕΔʂ

    View full-size slide

  17. 2005೥͔ΒRuby௮͚
    • RailsΛࢼͯ͠
    • ϒϩάॻ͍ͯ
    • ࡶࢽʹهࣄΛॻ͘

    View full-size slide

  18. OSC Hokkaido 2005
    • ͨͿΜॳΊͯMatzΛݟͨͷ͸͜ͷ࣌
    • جௐߨԋͷ࣭ٙԠ౴ΛӳޠͰ΍͍ͬͯͨ
    • ӳޠ͠Ό΂ΕΔͷ͸͍͍ͳͱࢥͬͨΒ͍͠

    View full-size slide

  19. RailsConf 2006
    • ॳΊͯͷւ֎
    • ӳޠྗθϩ
    • ϦΞϧRuby༑ୡ΋΄΅θϩ

    View full-size slide

  20. ॳͷւ֎ΧϯϑΝϨϯε
    • ӳޠ෼͔Βͳ͍͔ΒԿݴͬͯΔ͔෼͔Βͳ͍
    • εϥΠυݟΔͱͳΜͱͳ͘෼͔Δ
    • ࣮͸େͨ͜͠ͱΛݴͬͯͳ͍ʢؾ͕͢Δʣ
    • Railsษڧձ@౦ژͷํ͕εΰ͘ͳ͍ʁ

    View full-size slide

  21. ͳΒ౉ถ͠Α͏
    • RubyྺͳΒઈରࣗ෼ͷํ͕௕͍
    • ͜Ε͘Β͍ͷൃදɺ೔ຊޠͳΒࢲͰ΋ग़དྷΔ
    • ॅΊ͹ӳޠ͙Β͍Ͱ͖ΔΑ͏ʹͳΔΜ͡Όͳ͍ʁ

    View full-size slide

  22. ৭ʑ͋ͬͯ2008೥౉ถ
    • தౡ૱͞ΜͱೋਓͰBig Canvas, Inc.ઃཱ
    • γΞτϧʹҠॅ
    • iPhone޲͚ࣸਅڞ༗ΞϓϦPhotoShareΛϦϦʔ
    ε

    View full-size slide

  23. Seattle.rb
    • γΞτϧͷRubyίϛϡχςΟ
    • Nokogiriͷ@tenderlove΍ RubyGemsͷ@drbrain
    • ຖिΧϑΣͰmeet up
    • ӳޠ෼͔Βͳ͍͚ͲͳΜͱͳ͘ࢀՃ֮ͯ͑ͨ͠

    View full-size slide

  24. Appcelerator΁స৬
    • ஌Γ߹͍ͷ͍ͳ͍ίϛϡχςΟʔͰ׆ಈ͍ͨ͠
    • Node.jsͱTitanium Mobile
    • Titanium MobileʹύονૹͬͨΓνϟοτͰ࿩
    ͨ͠͠Γ͍ͯ͠Δ͏ͪʹதͷਓʹ

    View full-size slide

  25. ӨڹΛड͚ͨਓ

    View full-size slide

  26. ςΫϊϩδʔʹѪΛᨳ͏
    • ࢲͷΦʔϓϯιʔε΁ͷಈػͱ৘೤ͷݯ͸ѪͰ͢

    http://el.jibun.atmarkit.co.jp/rails/2012/10/ruby-matz-7080.html
    • ͳͥRubyΛѪ͍ͯ͠Δͷ͔ - ͦΕ͸೉͍࣭͠໰
    ͩɻ ͳͥԞ͞ΜΛѪ͍ͯ͠Δͷ͔؆୯ʹ͸౴͑Β
    Εͳ͍ΑͶɻ

    http://jp.rubyist.net/RubyKaigi2007/Log0610-S5.html

    View full-size slide

  27. ϩδΧϧ͡Όͳ͍

    View full-size slide

  28. Ѫ͸׮༰Ͱ͋ΓɺѪ͸਌੾Ͱ͢ɻ·ͨਓΛͶͨΈ·ͤΜɻ
    Ѫ͸ࣗຫͤͣɺߴຫʹͳΓ·ͤΜɻྱّʹ൓͢Δ͜ͱΛ
    ͤͣɺࣗ෼ͷརӹΛٻΊͣɺౖΒͣɺਓͷͨ͠ѱΛࢥΘͣɺ
    ෆਖ਼Λت͹ͣʹਅཧΛتͼ·͢ɻ͢΂ͯΛ͕·Μ͠ɺ͢
    ΂ͯΛ৴͡ɺ͢΂ͯΛظ଴͠ɺ͢΂ͯΛ଱͑೜ͼ·͢ɻ
    Ѫ͸ܾͯ͠ઈ͑Δ͜ͱ͕͋Γ·ͤΜɻ

    ʢίϦϯτਓ΁ͷखࢴI 13ɿ4ʙ8ʣ

    View full-size slide

  29. Matz
    Is

    Nice
    So
    We
    Are
    Nice

    View full-size slide

  30. Matz͸ετʔϦʔΛ

    ޠΔͷ্͕ख͍

    View full-size slide

  31. ॳΊͯͷRubyຊମ΁ͷ
    ߩݙ

    View full-size slide

  32. mruby
    • ૊ΈࠐΈ޲͚Ruby
    • શ͘৽͍࣮͠૷
    • RubyConf 2010Ͱฉ͍ͨ
    • ͔ͦͬΒਐḿΛશવฉ͔ͳ͍

    View full-size slide

  33. ΍Δ͜ͱଟ਺
    • ී௨ʹόά͕࢒ͬͯΔ
    • ίϯύΠϧࡁΈmrubyϑΝΠϧͷϑΥʔϚοτ
    • ϏϧυγεςϜ
    • RubyGems૬౰ͷγεςϜ

    View full-size slide

  34. GitHubҎޙͷ։ൃίϛϡχςΟ
    • ίʔυͷมߋ΍ߩݙ͕ՄࢹԽ͞Εͨ
    • ίϛϡχέʔγϣϯ͕ߏ଄Խ͞Εͨ
    • ίϛολͱίϯτϦϏϡʔλ۠ผ͕ബ͘ͳͬͨ

    View full-size slide

  35. MobiRuby
    • iOSͷΞϓϦΛRubyͰॻ͚Δ
    • Cocoa/Objective-CͱmrubyͷϒϦοδ
    • Titanium MobileͷΞʔΩςΫνϟͷ໰୊Λղফ

    View full-size slide

  36. MobiRubyͷ΋͘ΖΈ

    View full-size slide

  37. MobiRubyͷ΋͘ΖΈ

    View full-size slide

  38. Matzʹ͸ͳΕͳ͍

    View full-size slide

  39. Ruby͔ΒಘͨϞϊ
    • ٕज़ऀͱͯ͠ͷ෢ث
    • ΤϯδχΞϦϯάͷ஌ࣝ
    • ίϛϡχςΟʔͷखຊ
    • ଟ͘ͷ༑ਓɾଚܟͰ͖Δਓୡ

    View full-size slide

  40. Ruby͔ΒಘͨϞϊ

    View full-size slide