Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Speaker Deck
PRO
Sign in
Sign up for free
golang tokyo go tools
mom0tomo
April 19, 2019
Technology
3
1k
golang tokyo go tools
mom0tomo
April 19, 2019
Tweet
Share
More Decks by mom0tomo
See All by mom0tomo
最初の言語としてGoを学んだ人から見た Ruby on Rails
mom0tomo
1
420
はじめてみんなで作ったGoのツールの話
mom0tomo
0
120
人材業界 中の人が語る 若手エンジニアの転職活動
mom0tomo
0
330
Go-ビギナーズ - よくある3つの質問
mom0tomo
1
87
Go徒然日記
mom0tomo
0
1.1k
LTLovers meetup 1st - the core of "your" love -
mom0tomo
0
700
Other Decks in Technology
See All in Technology
SI企業が「アジャイル推し」になったら 幸せになれますか?/Can SI company be happy if it becomes “Agile stan” ?
chinmo
1
1.1k
要約 "Add Live Text interaction to your app"
ushisantoasobu
0
140
The application of formal methods in Kafka reliability engineering
line_developers
PRO
0
120
Design for Humans: How to make better modernization decisions
indualagarsamy
2
110
miisan's career talk
mii3king
0
220
FoodTechにおける商流・金流・物流の進化/Evolution of Commercial, Financial, and Logistics in FoodTech
dskst
0
380
ラブグラフ紹介資料 〜プロダクト解体新書〜 / Lovegraph Product Deck
lovegraph
0
130
アジャイル推進活動におけるBeAgileへの変化の兆し/Signs_of_Change_to_"Be_Agile"_in_Agile_Promotion_Activities
m_iyama
0
110
HoloLens2とMetaQuest2どちらも動くWebXRアプリをBabylon.jsで作る
iwaken71
0
180
How to start with DDD when you have a Monolith
javujavichi
0
110
さいきんのRaspberry Pi。 / osc22do-rpi
akkiesoft
4
4.8k
2022年度新卒技術研修「 ソフトウェアテスト」講義
excitejp
PRO
0
360
Featured
See All Featured
Building Better People: How to give real-time feedback that sticks.
wjessup
344
17k
What the flash - Photography Introduction
edds
61
10k
The Invisible Customer
myddelton
110
11k
The Language of Interfaces
destraynor
148
20k
Practical Orchestrator
shlominoach
178
8.6k
Web development in the modern age
philhawksworth
197
9.3k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
212
20k
The Invisible Side of Design
smashingmag
290
48k
Product Roadmaps are Hard
iamctodd
34
6.5k
Principles of Awesome APIs and How to Build Them.
keavy
113
15k
Put a Button on it: Removing Barriers to Going Fast.
kastner
56
2.3k
Support Driven Design
roundedbygravity
86
8.5k
Transcript
Go Λ͡ΊΔʹ͋ͨͬͯ ͓͍ͬͯͯ΄͍͠πʔϧ 2019/04/19 @golang.tokyo 1 The Go gopher was
designed by Renee French.
Who? • ެһʢࢁܗݝிʣ →WebσβΠφʔ →αʔόʔαΠυΤϯδχΞ w Women Who Go Tokyoελοϑ
!2 ID: mom0tomo
Women Who Go Tokyo Go͖͕ू·ͬͯɺ݄ʹҰςʔϚֶश͍ͯ͠·͢ !3
ΩʔΩϟοϓ൦͠·ͨ͠ ٕज़ॻయ#wwg_tokyo !4
͓ͬͯ͘ͱ ʹཱͭ͜ͱ !5
golang.orgΛࢀর͠Α͏ !6
golang.orgΛࢀর͠Α͏ golang.jp༰͕WҎલͳͷͰҙ͢Δ !7
Gophers.slack.comʹࢀՃ͠Α͏ !8
Gophers.slack.comʹࢀՃ͠Α͏ https://invite.slack.golangbridge.org/ !9
Golang WeeklyΛಡ͏ !10
!11 ͍ͬͯΔͱ ศརͳπʔϧ
Go ίϚϯυ/πʔϧ͕ॆ࣮ͯ͠ ͍Δ • go ίϚϯυ • go tool •
ඪ४ɾ४ඪ४ύοέʔδͰఏڙ͞Ε͍ͯΔ • IDEʹཔΒͳͯ͘շదʹ։ൃͰ͖Δ
ڥมΛදࣔ͢Δ $ go env 13
$ go env GOARCH="amd64" GOBIN="" GOCACHE="/home/alex/.cache/go-build" GOEXE="" GOFLAGS="" GOHOSTARCH="amd64" GOHOSTOS="linux"
GOOS="linux" GOPATH="/home/alex/go" GOPROXY="" GORACE="" GOROOT="/usr/local/go" GOTMPDIR="" GOTOOLDIR="/usr/local/go/pkg/tool/linux_amd64" GCCGO="gccgo" CC="gcc" CXX="g++" CGO_ENABLED="1" GOMOD="" CGO_CFLAGS="-g -O2" CGO_CPPFLAGS="" CGO_CXXFLAGS="-g -O2" CGO_FFLAGS="-g -O2" CGO_LDFLAGS="-g -O2" PKG_CONFIG="pkg-config" GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go- build245740092=/tmp/go-build -gno-record-gcc-switches" 14
$ go env GOPATH GOROOT /Users/mom0tomo/dev/go /usr/local/go // ಛఆͷڥมΛൈ͖ग़ͯ͠දࣔ͢Δ 15
ίʔυΛformat͢Δ $ gofmt $ go fmt 16
$ gofmt . $ gofmt foo.go // Options // -d
: diffΛඪ४ग़ྗ͢Δ // -l : ϑΝΠϧ໊Λඪ४ग़ྗ͢Δ // -w : ্ॻ͖อଘ͢Δ // -s : ه๏Λγϯϓϧʹ͢Δ // Ұཡ https://godoc.org/github.com/gophersjp/go/src/cmd/gofmt 17
$ go fmt . $ go fmt foo.go // $
gofmt -l -w ͱಉͨ͡Β͖ // formatͨ͠༰Ͱ্ॻ͖ͯ͠ϑΝΠϧ໊Λඪ४ग़ྗ͢Δ 18
ίʔυΛ੩తղੳͯ͠ ଥੑΛνΣοΫ͢Δ $ go vet 19
$ go vet . $ go vet foo.go // ίʔυΛ੩తղੳͯ͠ه๏ΛνΣοΫ͢Δ
// ίϯύΠϥʹݕͰ͖ͳ͍ͷΛݟ͚ͭͯ͘ΕΔ 20
Ϧϯλʔʹ͔͚Δ $ golint 21
$ golint . $ golint foo.go // ίʔυ͕Effective GoͱCodeReviewCommentsʹ Ԋ͏͔νΣοΫ͢Δ
22
Thank you! @mom0tomo 23