Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
CircleCI Go Code Inspection
Search
Kazuki Higashiguchi
May 28, 2019
Technology
750
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
CircleCI Go Code Inspection
GoプロジェクトでのCircleCIによるコード検査 について #circlecijp
Kazuki Higashiguchi
May 28, 2019
More Decks by Kazuki Higashiguchi
See All by Kazuki Higashiguchi
Practical Monitoring for Knative Serving / KubeCon + CloudNativeCon Japan 2025
hgsgtk
0
160
Cell-Based Architecture Design in AWS
hgsgtk
1
280
インフラコストとセキュリティ課題解決のためのリアーキテクチャリング / srekaigi2025
hgsgtk
3
8.8k
Design of a Stateful system for Robust Deployment and Observability
hgsgtk
0
1.6k
A guide to joining operational work in your new DevOps team
hgsgtk
1
1.7k
HTTP Tunneling in Go
hgsgtk
0
1.7k
ブラウザ自動操作技術の深層へ、直接触れて学ぶ WebDriver と Chrome DevTools Protocol
hgsgtk
3
7.1k
HTTP Server on random available port in Go
hgsgtk
0
1.2k
Agile Testingを夢見たテスト自動化 〜ATDDへの挑戦から始まる 1年間の試行錯誤〜 / dreaming agile testing at basebank
hgsgtk
13
8.6k
Other Decks in Technology
See All in Technology
味覇で作るパスタが美味い - 20261001_yabaubuki.dev
livesense
PRO
0
120
オンラインゲームのシステム全体像 - コロプラ 2026年度 新卒研修
colopl
0
1k
初対面のメンバーがチームを組み、Claude Codeでゼロからサービスをリリース
mkdev10
1
120
FOSS4Gを活用した自治体業務DXの試み
470715
0
140
V8のArray.prototype.flatを最大約20倍速くするまでと、巨大OSSへの大規模コミットの道のり
riyaamemiya
0
120
継続的なAIコスト最適化
bgpat
1
270
分析の民主化を支えるメタデータ整備の実践
kakehashi
PRO
4
1.2k
SREでアラート疲れを 解決しよう!
kairim0
1
220
今さら理解するウェブフォントver.2026
takanorip
3
600
検証フェーズはAIの回答を判断するための学習機会
toru_kubota
2
560
1万名の社員が使う認証基盤で どう信頼性を担保するか?
kairim0
0
220
Deep Data Security 機能解説
oracle4engineer
PRO
2
750
Featured
See All Featured
Faster Mobile Websites
deanohume
310
32k
WCS-LA-2024
lcolladotor
0
860
Stewardship and Sustainability of Urban and Community Forests
pwiseman
0
540
Claude Code のすすめ
schroneko
67
230k
Building AI with AI
inesmontani
PRO
1
1.3k
A Guide to Academic Writing Using Generative AI - A Workshop
ks91
PRO
1
510
Test your architecture with Archunit
thirion
2
2.4k
Designing for Performance
lara
612
70k
How to build an LLM SEO readiness audit: a practical framework
nmsamuel
2
940
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.9k
What the history of the web can teach us about the future of AI
inesmontani
PRO
2
730
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4.6k
Transcript
© - BASE, Inc. X Goプロジェクトでの CircleCIによるコード検査 . . #circlecijp-
@hgsgtk
© - BASE, Inc. : @hgsgtk ⾃⼰紹介 東⼝ 和暉 (
Higashiguchi Kazuki ) サーバーサイドエンジニア BASE BANK, Inc CircleCIに チョットお世話になってます
© - BASE, Inc. このトークで得られること • GoプロジェクトにおけるCircleCIの活⽤事例 • 「どういうチェックしてる?」 •
Lint‧テスト実⾏する config.yml • 「実際、どう設定するの?」 • プロジェクトでのCircleCI活⽤⽅法振り返り知⾒ • 「こういう活⽤の仕⽅は良かった。」
© - BASE, Inc. お題⽬ • プロジェクトにおけるCircleCI利⽤の全体像 • コード検査を⾏うための config.yml
の中⾝ • CircleCIを利⽤したプロジェクトの振り返り
© - BASE, Inc. プロジェクトにおけるCircleCI利⽤の全体像 https://devblog.thebase.in/entry/ / / /
© - BASE, Inc. プロジェクトにおけるCircleCI利⽤の全体像 https://devblog.thebase.in/entry/ / / / このトークの
スコープ
© - BASE, Inc. 全体像 .circleci/config.yml (コード検査部分)
完全に理解 しましたね?
© - BASE, Inc. 全体像 .circleci/config.yml (コード検査部分) . 依存パッケージ解決 .
フォーマットチェック . Lintチェック . ビルド‧テスト . 循環複雑度計測
© - BASE, Inc. 1. 依存パッケージ解決 • Goの依存パッケージ関係 解決に Go
Modules を利 ⽤ • See also: https://circleci.com/ blog/go-v . -modules-and- circleci/ • circleci/golang >= . . を利⽤ • Go . MODULE = “on”
© - BASE, Inc. 2. フォーマットチェック • `go fmt`でフォーマット チェック
• ※ 依存パッケージ解決にて vendor ディレクトリが作成される場合は vendorは除く設定が必要。 • `go fmt`の結果をstderrへ
© - BASE, Inc. . Lintチェック • `golangci-lint run`の結果をstderrへ •
golangci-lint を利⽤ • GolangCI-Lint is a linters aggregator • See also: https://github.com/ golangci/golangci-lint
© - BASE, Inc. . Lintチェック - golangci-lintのconfig • 設定
.golangci.yml • 複数のチェックツールを まとめて実⾏することが できる
© - BASE, Inc. 4. ビルド‧テスト • `go build`にてビルド •
ビルドができるかをチェッ クする • `go test`にてテスト go test -p -race -cover ./...
© - BASE, Inc. 5. 循環複雑度計測 • 循環複雑度とは • ソフトウェ測定法の⼀つ
• プログラムの複雑度を測 る • fzipp/gocyclo を利⽤した 循環複雑度計測 • See also: https://github.com/ fzipp/gocyclo
© - BASE, Inc. CircleCIを利⽤したプロジェクトの振り返り • CIが開発者にGo流を教えてくれる • コードを書く前にlint‧テストを設定した •
チェックツールの追加に対する変更が発⽣ • golangci-lintは途中から⼊れた • (※ go vet/go importsと⼊れ替え) • 最初は思いつく限り多めに⼊れて、外していくのが いいと思う
© - BASE, Inc. 余談:デプロイパイプランについて知りたい⽅は https://devblog.thebase.in/entry/ / / /
© - BASE, Inc. 余談:デプロイパイプランについて知りたい⽅は https://devblog.thebase.in/entry/ / / / 「CircleCIとecspressoによるECSへのデプロイメントパイプライン」
https://devblog.thebase.in/entry/ / / /
Thanks