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
Git Flow and Coding Style
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Bo-Yi Wu
January 24, 2016
Technology
0
71
Git Flow and Coding Style
Bo-Yi Wu
January 24, 2016
Tweet
Share
More Decks by Bo-Yi Wu
See All by Bo-Yi Wu
戰略轉變:從建構 AI 代理人到發展可擴展的技能生態系統
appleboy
0
210
The Smart Choice for Command-Line Image Resizing
appleboy
0
16
SSH for GitHub Actions
appleboy
0
64
打 造 A I 驅 動 的 G i t H u b ⾃ 動 化 ⼯ 作 流 程
appleboy
0
600
Connecting Your Worlds: A Guide to Integrating GitHub Actions and Jenkins
appleboy
0
90
From Natural Language to K8s Operations: The MCP Architecture and Practice of kubectl-ai
appleboy
0
1.2k
What’s MCP && Authorization?
appleboy
0
100
Building a Unified API Gateway for Secure and Scalable Cross-Cloud AI Service
appleboy
0
1.8k
Building MCP (Model Context Protocol) with Golang
appleboy
0
3.4k
Other Decks in Technology
See All in Technology
Agile Leadership Summit Keynote 2026
m_seki
1
560
学生・新卒・ジュニアから目指すSRE
hiroyaonoe
2
580
AIと新時代を切り拓く。これからのSREとメルカリIBISの挑戦
0gm
0
840
Embedded SREの終わりを設計する 「なんとなく」から計画的な自立支援へ
sansantech
PRO
3
2.3k
茨城の思い出を振り返る ~CDKのセキュリティを添えて~ / 20260201 Mitsutoshi Matsuo
shift_evolve
PRO
1
220
We Built for Predictability; The Workloads Didn’t Care
stahnma
0
130
Context Engineeringの取り組み
nutslove
0
310
データの整合性を保ちたいだけなんだ
shoheimitani
8
3k
会社紹介資料 / Sansan Company Profile
sansan33
PRO
15
400k
SREが向き合う大規模リアーキテクチャ 〜信頼性とアジリティの両立〜
zepprix
0
420
AzureでのIaC - Bicep? Terraform? それ早く言ってよ会議
torumakabe
1
470
CDK対応したAWS DevOps Agentを試そう_20260201
masakiokuda
1
220
Featured
See All Featured
Embracing the Ebb and Flow
colly
88
5k
Agile Actions for Facilitating Distributed Teams - ADO2019
mkilby
0
110
The Invisible Side of Design
smashingmag
302
51k
How to Grow Your eCommerce with AI & Automation
katarinadahlin
PRO
0
110
The Power of CSS Pseudo Elements
geoffreycrofte
80
6.2k
Tell your own story through comics
letsgokoyo
1
810
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
31
3.1k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
254
22k
DevOps and Value Stream Thinking: Enabling flow, efficiency and business value
helenjbeal
1
91
The Straight Up "How To Draw Better" Workshop
denniskardys
239
140k
Site-Speed That Sticks
csswizardry
13
1.1k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
333
22k
Transcript
Git Flow and Coding Style Bo-Yi Wu 2015/04/10
Agenda • Git merge vs Git rebase. • JavaScript Coding
Style.
Git merge vs Git rebase
Git merge • Create your branch – $ git checkout –b
‘response’ • Merge from develop branch – $ git merge develop
None
git merge develop
None
New commit Merge branch 'develop' into response (HEAD, response)
None
git merge develop again
None
New commit Merge branch 'develop' into response (HEAD, response)
git checkout develop git merge --no-ff response
None
Git rebase • Create your branch – $ git checkout –b
‘response’ • Merge from master branch – $ git rebase develop
None
Git rebase master
None
No more new commit log
Git rebase master again
None
No more new commit log
Create your new Pull Request git merge --no-ff respnse
None
git rebase vs git merge network graph
None
Rebase vs Merge 優缺點 rebase merge 避免過多 merge
commit log 產生 merge commit log Branch commit log 排到最前面(方便追 蹤) 依照時間排序 commit log network graph 清楚 network graph 不易理解 各別 commit 解決 conflict 一次將全部衝突顯示 可任意修改 commit log 可合併多個 commit (避免過多無意義 commit log)
Rebase vs Merge 使用時機 rebase merge 整理 Branch
commit log 主分支記錄合併 xxxx branch 非主分支開發無需記錄何時合併主分支 主分支請勿使用 rebase 合併任何分支
Develop Note Please rebase master branch and test again before
creating new Pull Request
JavaScript Coding Style Guide
原先架構 https://google-styleguide.googlecode.com/svn/trunk/javascriptguide.xml
Google JavaScript Style Guide 無任何範例可參考
Airbnb JavaScript Style Guide https://github.com/airbnb/javascript
Airbnb JavaScript Style Guide 程式碼範例完整 另外也可以參考 ES6 Branch
Yoda Conditions https://en.wikipedia.org/wiki/Yoda_conditions if ($a === ‘1’) { // code
block } if (‘1’ === $a) { // code block } 程式閱讀性高 程式閱讀性低
Yoda Conditions https://en.wikipedia.org/wiki/Yoda_conditions if ($a = ‘1’) { // code
block } 避免此種情況發生
How to prevent the condition? Write Unit Test
Thanks