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
メルカリ社員100人に聞いたGoLandの使い方 / JetBrains Night Toky...
Search
Masahiro Wakame
November 20, 2018
Programming
27
13k
メルカリ社員100人に聞いたGoLandの使い方 / JetBrains Night Tokyo 2018
https://info.jetbrains.com/jetbrains-night-tokyo-2018.html
Masahiro Wakame
November 20, 2018
Tweet
Share
More Decks by Masahiro Wakame
See All by Masahiro Wakame
DatastoreからSpannerに 移行したいぞ途中編 / migrate Datastore to Spanner in progress
vvakame
0
1k
Google Cloud Next 2019 わくわく報告会 / Google Cloud Next 2019 WakuWaku Report
vvakame
1
410
OSS入門 世界に参加する最初のひと押し / OSS first step
vvakame
7
690
GCP Compute 概要と選定 / DevFest Tokyo 2018
vvakame
12
1.6k
GoでGraphQLサーバを立てるぞ! / Building GraphQL server by go
vvakame
15
4.6k
『Re:VIEW+CSS組版やっていき』を やった話とWebエンジニアが期待する未来 / CSS Publishinng for Web Developers
vvakame
3
8.7k
go.mercari.io/datastore はいいぞ! / go.mercari.io/datastore is pretty good!
vvakame
4
1k
最強のDatastoreライブラリを作った / golang.tokyo #11
vvakame
3
10k
GAE/Go 1.8化の話題とnouhauの話 / yappari appengine ja night #2
vvakame
0
800
Other Decks in Programming
See All in Programming
카카오페이는 어떻게 수천만 결제를 처리할까? 우아한 결제 분산락 노하우
kakao
PRO
0
110
Ethereum_.pdf
nekomatu
0
460
初めてDefinitelyTypedにPRを出した話
syumai
0
420
Macとオーディオ再生 2024/11/02
yusukeito
0
370
シェーダーで魅せるMapLibreの動的ラスタータイル
satoshi7190
1
480
Jakarta EE meets AI
ivargrimstad
0
590
ピラミッド、アイスクリームコーン、SMURF: 自動テストの最適バランスを求めて / Pyramid Ice-Cream-Cone and SMURF
twada
PRO
10
1.3k
Amazon Bedrock Agentsを用いてアプリ開発してみた!
har1101
0
340
Generative AI Use Cases JP (略称:GenU)奮闘記
hideg
1
300
Less waste, more joy, and a lot more green: How Quarkus makes Java better
hollycummins
0
100
Flutterを言い訳にしない!アプリの使い心地改善テクニック5選🔥
kno3a87
1
200
『ドメイン駆動設計をはじめよう』のモデリングアプローチ
masuda220
PRO
8
540
Featured
See All Featured
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
226
22k
Building a Scalable Design System with Sketch
lauravandoore
459
33k
GraphQLとの向き合い方2022年版
quramy
43
13k
What’s in a name? Adding method to the madness
productmarketing
PRO
22
3.1k
Testing 201, or: Great Expectations
jmmastey
38
7.1k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
191
16k
Writing Fast Ruby
sferik
627
61k
It's Worth the Effort
3n
183
27k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
10
720
XXLCSS - How to scale CSS and keep your sanity
sugarenia
246
1.3M
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
356
29k
A Tale of Four Properties
chriscoyier
156
23k
Transcript
ϝϧΧϦࣾһ100ਓʹ ฉ͍ͨGoLandͷ͍ํ JetBrains Night Tokyo 2018 Θ͔Ί ·͞ͻΖ
Θ͔Ί ·͞ͻΖ @v vakame Masahiro Wakame Go GraphQL TypeScript
Q. ຊʹ100ਓʹฉ͍ͨʁ
Q. ຊʹ100ਓʹฉ͍ͨʁ
Q. ຊʹ100ਓʹฉ͍ͨʁ ड़ਓ 372ਓ ʹ ฉ͖·ͨ͠ʂʂ
ࠓͷαϚϦ ΈΜͳʹฉ͍ͨ ूେΛ͠·͢ʂ
ࠓͷαϚϦ •GoLand ཱࣗɾࣗशͷͨΊͷΈ •IDEʹٻΊΔػೳ •GoLandͷศརͳػೳͨͪ
֤OSຖͷ •macOSϢʔβͰ͢ •ࠓجຊmacOSϕʔε •Action໊͕Θ͔ΕOK •͋ͱͰઆ໌͠·͢
ཱࣗɾࣗशͷͨΊͷΈ
GoLandଟػೳͰ͋Δ •ػೳ͕ແݶʹ͋Δ •Βͳ͍ػೳ͏͜ͱ͕Ͱ͖ͳ͍ •Ͳ͏ͬͯڧ͘ͳΕ͍͍Μͩ… ·ͣษڧͷํ͔Β
Productivity Guide •༁͢Δͱੜ࢈ੑΨΠυ •Help > Productivity Guide •ීஈͬͯͳ͍ػೳʹ •ਓͷΛݟΔͱ݁ߏָ͍͠
Find Action •ActionΛ୳͢ •Help > Find Action •ࠓ͜Ε͚֮ͩ͑ͯؼͬͯʂ •͍͍ͩͨͷͷ͕Action Cmd+Shift+A
Find Action ͍͍ͩͨ Կ͔ Actionͩʂ
Find Action ຊࢿྉ Action໊Λ ໌ه͠·͢
Search Everywhere •ͳΜͰݕࡧ • ͜Ε •ϑΝΠϧ, ܕ, Action ͳʹ͔͔Βݕࡧ Shift
Shift ࠔͬͨΒShift࿈ଧϚϯ
Preferencesͷݕࡧ •ݕࡧܥػೳ΄Μͱॆ࣮͍ͯ͠Δ
ϖΞ ϓϩάϥϛϯά •Ұ൪ϕʔγοΫͳͭ •ਫ਼ਆతෑډͪΐͬͱߴ͍ •Ҋ֎ΈΜͳ͍ํ͕όϥ͚Δ •γϣϧμʔαʔϑΟϯ͢Δͷָ͕ ڐՄऔΖ͏ʂ
Tip of the Day •ศརใΛϥϯμϜʹදࣔ •Help > Tip of the
Day •ҰؾʹෳݟΔͱָ͍͠ •গͣͭ͠ڧ͘ͳΖ͏ʂ
Presentation Assistant (Plugin) • github.com/chashnikov/IntelliJ-presentation- assistant • γϣʔτΧοτΩʔදࣔϓϥάΠϯ Unofficial PluginͰ͢
Key Promotor X (Plugin) • github.com/halirutan/IntelliJ-Key-Promoter-X • γϣʔτΧοτΩʔڭҭϓϥάΠϯ • Ϛεͱ͔͏ͱࢦಋ͞ΕΔ
Unofficial PluginͰ͢
•Preference > Keymap > γϣʔτΧοτٯҾ͖ ਓ͔ΒڭΘΔ࣌ศར ͻͬͦΓͯ͠·͢
খ͍͞Ϙλϯશ෦ԡ͢ •݁ߏݟಀ͚͢Ͳਵॴʹ͋Δ ͱΓ͋͑ͣԡ͠·͠ΐ͏
ෆຬΛݟಀ͞ͳ͍ •ෆศʹ׳Εͳ͍΄͏͕Α͍ •ղফͯ͠Γӽ͍͖͍͑ͯͨ •ݴ͏қ͘ߦ͏͠… ୳ͤ(͍͍ͩͨ)͋Δʂ
ϒϩάͱ͔ݟΔ •blog.jetbrains.com/go/ •blog.jetbrains.com/jp/category/goland •samuraism.com/jetbrains/training ࡢϓογϡ͞ΕͨͷͰ…(ૉ
IDEʹٻΊΔػೳ
Goͷύοέʔδཧ •܈༤ׂڌ •Dep •Go Modules (Official) •↑Experimental GoLandGo Modulesαϙʔτࡁ
Go Modules •GO111MODULE=on •࠷ߴͷαϙʔτʂ ͜Εͦ͜ސ٬͕ٻΊ͍ͯͨͷ…ʂ
Go Module •GoLandͷGo Moduleαϙʔτ࠷ߴ(࠶ܝ •$GOPATH ͷมͳpackageरΘͳ͍ •↑ͪΐ͍ͪΐ͍ਏ͔ͬͨ… •IDEͱͯ͠ͷ͕͕͋ͬͨ(ؾʹͳΔ
σόοΨ •ී௨ʹ͑Δ (Delve͕backend •Break point / Inspector •Unit TestपΓͷαϙʔτॆ࣮ •Ͱ͖ͳ͍…
•ෳࡶͳEvaluate Expression / Set Value
AppEngineαϙʔτ •Google Cloud PlatformͷAppEngine •ͬͯ·͔͢ʁͬͯ·͢Ͷʁ •go111 runtimeͰΊͬͪΌָʹͳͬͨ •AppEngineଆ͕าΈد͖ͬͯͨܗ •2018.3 Ͱچruntimeͷαϙʔτվળ
ΊͬͪΌ͍͚ͨ͠Ͳधཁബͦ͏ͳͷͰ࠙ձͰ…
ίʔυิ •ී௨ͷαδΣετ •ςετੜ •Struct ͷFieldຒΊ •etc…
πʔϧྨ…ʁ •gofmt, goimportsͳͲ •αϙʔτ༗Γ •νʔϜͰ౷Ұ͢ΔͨΊಛఆͷΤσΟλʹ ґଘͨ͘͠ͳ͍ؾ࣋ͪ… •gometalinter → File Watcher
ଞΤσΟλϢʔβʹฉ͍ͨ
Vim •IdeaVim Plugin •ΠέΔ •ͭΒ͍ •Undoͷڍಈ͕ਏ͍… plugins.jetbrains.com/plugin/164-ideavim
ίʔυิͱ͔͍Δͷ ݾΛ͑Ε Α͘ͳ͍Ͱ͔͢ʁ ※ݸਓͷײͰ͢(ͬͯݴ͑ͬͯ
GoLandͷศརͳػೳͨͪ ৭ʑग़͖ͯ·ͨ͠
Show Intention Action •ͦͷ࣌ศརͦ͏ͳΞΫγϣϯΛදࣔ •Կ͔͋Γͦ͏ͱࢥͬͨΒͱΓ͋͑ͣԡ͢ •Quick Fix ʹ͍ۙ •WarningError͕ͳͯ͘ԡͤΔ Option
+ Enter
Test (Cmd+Shift+T) •Code ⇔ Test ͷҠಈ •Testͷੜ •Table Driven TestͳςϯϓϨΛੜʂ
•ςετ໊ؔΘΓͱྑ͍ Table Driven Testͯ͠·͔͢ʁ
Fill struct recursively •ͱͯ͠struct࡞Δ࣌ʹศར •zeroͰҰ୴શ෦ຒΊͯ͘ΕΔ Testॻ࣌͘ʹΑ͍͘·͢
Mark Directory as •Excludes ͱ͔͢Δ •ݕࡧͱ͔ʹҾ͔͔ͬΒͳ͘ͳΔ ͿͬͪΌ͚͋Μ·Θͳ͍
Declaration •ఆٛʹඈͿͭ •͜ͷϝιουͷ࣮Ͳ͏ͳͬͯΔͷʙ •Jump to Source ͱҧ͍͕Θ͔Βͳ͍… •GoҎ֎ͷݴޠͩͱҧ͏ͷ͔ͳ ͍ͭτϥοΫύουͰૢ࡞͢Δͭ
Back •1ݸલͷॴʹΔͭ •DeclarationͱΈ߹Θͤͯසൟʹ͏ •࠷ۙ·ͰΒͳͯ͘ෆศͩͱࢥͬͯ ·ͨ͠…
Next Project Window •ผ૭Ͱ։͍͍ͯΔProjectʹҠಈ͢Δͭ •ɹ͔ͨ͠ʹ •͔ɺ͔͍͍ͬ͜…
Edit Custom VM Options •GoLandͷىಈΦϓγϣϯ͍͡ΕΔ •-XmxΛ૿͢ʂͱ͍͏ਓ͕ଟ͔ͬͨ •JVMͷ࠷େώʔϓαΠζ • -Xmx1920m ʹ͠·ͨ͠
Recent Files •Recent Edited Files ͋ΔΑʂ
•͜ͷInterfaceΛ࣮ͯ͠ΔͭͲ͍ͭʁ •Methodͷ࣮ͷҰཡͱ͔ग़ͤΔ Implementations ݁ߏසൟʹ͏…ʂΊͬͪΌྑ͍
Call Hierarchy •ؔͳͲͷݺͼग़͠πϦʔΛදࣔ •Find Usage ΑΓศར…ʂ •࠶ؼతʹḷΕΔ Find Usageͣͬͱͬͯͨ…
Scratch File •GoͰී௨ʹ͑Δ •ಉ྅ͱίʔυͷ૬ஊ͍ͨ͠… •Playground → ิͳͯ͘ࢮ͵ •Scratch FileͰॻ͍ͯShare͢Δ ৽نϫʔΫεϖʔε४උΊΜͲ͍
JetBrains Toolbox •www.jetbrains.com/toolbox/ •GoLand ͦͷଞIDEೖΕΔͷΒ͘Β͘ •όʔδϣϯݻఆͱ͔Ͱ͖Δ •ΞϓσϥΫϥΫʂ Actionͱ͔Ͱͳ͍͚Ͳ…
Implement Interface •͋Δstructͱ͔ʹඞཁͳϝιουΛ ͼΌͬʂͱੜͤΔ implement missing method Ͱ͢
Implements missing method •Γͳ͍ϝιουΛͼΌͬʂͱੜͤΔ ίϯύΠϥʹinterface࣮νΣοΫͤ͞ΒΕΔ
File… :Line:Column •File Ͱ :ߦ൪߸:ྻ൪߸ Ͱ֘ҐஔʹඈΔ σόοάָ͕ʂ
Next Highlighted Error •Warning, Error etc ʹδϟϯϓͰ͖Δ •ίϯύΠϧΤϥʔͷमਖ਼࣌ʹศར
Show tabs in one row •Preferences > Editor > General
> Editor Tabs •Show tabs in one row Λ disable ʹ͢Δ •λϒද͕ࣔ1ߦʹͳΔͷෆศͩΑͶ… •શ෦ݟ͑ͯΔͱͤ
Camel Case matching •ೖྗิͰ໊લΛશ෦ଧͭඞཁͳ͍ •େจࣈ෦͚ͩͱ͔Ұ෦͚ͩͰOK ͜͏͍͏໊લͷͭ͋ͬͨΑͳ…ʁ Ͱίʔυ͕ॻ͚·͢(υΩϡϝϯτಡ͏
Quick Documentation •υΩϡϝϯτ͕γϡοͱݟΕ·͢ •External Documentation͋ΔΑʂ •godocͷWebϖʔδ͕γϡοͱ։͘
Find in Path •ϓϩδΣΫτશମݕࡧͱ͔ •Τϥʔϝοηʔδ͔ΒൃੜՕॴௐͨΓ •Replace in Path Α͍͘·͢
࠷ޙʹ
We are hiring! •͞ΒͳΔใࣾWikiSlackͰʂ •ΞΫηε͢Δʹೖࣾ͢Δ͔͠ͳ͍…ʂ •ϝϧΧϦˠ careers.mercari.com/ •ϝϧϖΠˠ jp.merpay.com/careers/
None