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
Ship cli tools for cross-platform with Github +...
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
TANABE Ken-ichi
September 26, 2014
Technology
1.4k
0
Share
Ship cli tools for cross-platform with Github + wecker
TANABE Ken-ichi
September 26, 2014
More Decks by TANABE Ken-ichi
See All by TANABE Ken-ichi
AAA: An ACME Agent for AWS environment
nabeken
0
3.5k
Introduction to Terraform
nabeken
0
2.7k
The Twelve-Factor Apps
nabeken
0
74
Go and License
nabeken
8
11k
Other Decks in Technology
See All in Technology
AI Engineering Summit Tokyo 2026 AIの前に、やることがある 〜医療データ企業の4フェーズ〜
dtaniwaki
0
1.4k
AIガバナンス実践 - 生成AIコネクタのデータ漏洩リスクと実務対策
knishioka
0
170
Gradle×GitHub_ActionsでCI時間を約50%短縮 ジョブ分割の設計と落とし穴 / Cutting CI Time by ~50% with Gradle and GitHub Actions: Job-Splitting Design and Pitfalls
takatty
0
610
Java正規表現エンジン(NFA)の仕組みと パフォーマンスを維持するための最適化手法
takeuchi_132917
0
180
価格.comをAI駆動で全面刷新する ー 30年分の技術的負債を返し、次の30年の土台をつくる ー / AI Engineering Summit Tokyo 2026
tkyowa
35
37k
OpenID Connectによるサービス間連携
takesection
0
150
AI時代の私の技術インプットとアウトプット術
tonkotsuboy_com
16
8.3k
TROCCOで始めるクラウドコストを民主化するためのFinOps
tk3fftk
3
560
Agentic ERPをどう設計するか ー 受発注エージェントを動かす、現場の知見と設計思想ー
recerqainc
1
1k
【Gen-AX】20260530開催_JJUG CCC 2026 Spring
genax
0
390
「速く作る」から「正しく作る」へ ─ 生成AI時代の開発フロー改革の ロードマップと実行 ─
starfish719
0
5.6k
GoとSIMDとWasmの今。
askua
3
480
Featured
See All Featured
How to Think Like a Performance Engineer
csswizardry
28
2.6k
A better future with KSS
kneath
240
18k
Un-Boring Meetings
codingconduct
0
310
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
0
170
How To Stay Up To Date on Web Technology
chriscoyier
790
250k
Done Done
chrislema
186
16k
GraphQLとの向き合い方2022年版
quramy
50
15k
Reality Check: Gamification 10 Years Later
codingconduct
0
2.2k
Rebuilding a faster, lazier Slack
samanthasiow
85
9.5k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
49
3.5k
How To Speak Unicorn (iThemes Webinar)
marktimemedia
1
480
The AI Search Optimization Roadmap by Aleyda Solis
aleyda
1
5.9k
Transcript
Ship cli tools for cross- platform w/Github + wecker 2014/09/26@HDE
MTS TANABE Ken-ichi
動機 • OS X, Linux, Windows向けにcliツールを配布 したい • 開発者以外にも使ってほしい ◦
APIを叩いて何か処理をしたり ◦ 簡単なサーバを起動してデータをやりとりしたり • いつものようにCIしつつビルド、リリースまで自動 化したい
道具 • Go ◦ クロスプラットフォーム (OS X, Linux, Windows, BSD)
◦ 単一バイナリ ◦ 豊富な標準ライブラリ (syscallからnet/httpまで) • Github ◦ ソースコードリポジトリ • Wercker ◦ ビルド環境を自由に作成できるCI as a Service ◦ goxcを使い、クロスコンパイル ◦ 成果物をGithub Releasesへデプロイ
goxc • goxcを使うと以下を自動的に実行 ◦ 各プラットフォーム向けツールチェインのビルド (必要なら) ◦ クロスコンパイル ◦ プラットフォーム毎にアーカイブ
• goxcももちろんGoで書かれていてダウンロードする だけで動作する goxc -tasks='xc archive' -bc 'linux,amd64,386 darwin,amd64,386'
wercker (workerと読む) • Dockerのコンテナのように ビルド環境をboxとして自 由に構築、共有できる • 成果物のデプロイプロセス も定義できる •
サービスはまだベータの 位置付け
wercker (build) • YAMLでビルドプ ロセスを定義 • go {get, build, test,
fmt} • 最後にgoxcでビ ルド
wercker (one-click deployment) herokuなどのPaaS にもデプロイ可能
wercker (deploy) • UIから手動デプロイ • 特定ブランチへの pushに応じて自動 デプロイ
参考文献 • “pecoのバイナリ配布の話” http://lestrrat.ldblog.jp/archives/39736492.html • “Wercker で Go のプロジェクトをクロスコンパイルし、 Github
にリリースする” http://motemen.hatenablog. com/entry/2014/06/27/xcompile-go-and-release-to- github-with-wercker • nabeken/docker-cleaner (上をまねて作った) https://github.com/nabeken/docker-cleaner