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
refactoring
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
coldclimate
July 16, 2012
Technology
1
130
refactoring
a talk about making code more betterer. Contains invented words and a little swering
coldclimate
July 16, 2012
Tweet
Share
More Decks by coldclimate
See All by coldclimate
You don't scale like servers scale
coldclimate
0
140
Quick and dirty load testing with Vegeta
coldclimate
3
4.2k
Continuously deploying https served statically compiled sites to S3 with canonical domains
coldclimate
0
75
Scripting creating AWS based servers
coldclimate
0
320
Scaling CANDDi
coldclimate
0
310
Other Decks in Technology
See All in Technology
AI が Approve する開発フロー / How AI Reviewers Accelerate Our Development
zaimy
1
250
ヘルシーSRE
tk3fftk
2
210
俺の失敗を乗り越えろ!メーカーの開発現場での失敗談と乗り越え方 ~ゆるゆるチームリーダー編~
spiddle
0
420
Webアクセシビリティ技術と実装の実際
tomokusaba
0
160
生成AI活用によるPRレビュー改善の歩み
lycorptech_jp
PRO
4
1.8k
OCI技術資料 : 外部接続 VPN接続 詳細
ocise
1
10k
失敗できる意思決定とソフトウェアとの正しい歩き方_-_変化と向き合う選択肢/ Designing for Reversible Decisions
soudai
PRO
8
1.4k
2026-02-24 月末 Tech Lunch Online #10 Cloud Runのデプロイの課題から考えるアプリとインフラの境界線
masasuzu
0
110
社内ワークショップで終わらせない 業務改善AIエージェント開発
lycorptech_jp
PRO
1
430
男(監査)はつらいよ - Policy as CodeからAIエージェントへ
ken5scal
5
690
マイグレーションガイドに書いてないRiverpod 3移行話
taiju59
0
330
LINEアプリ開発のための Claude Code活用基盤の構築
lycorptech_jp
PRO
1
1.1k
Featured
See All Featured
WCS-LA-2024
lcolladotor
0
470
The Anti-SEO Checklist Checklist. Pubcon Cyber Week
ryanjones
0
83
State of Search Keynote: SEO is Dead Long Live SEO
ryanjones
0
140
Building Experiences: Design Systems, User Experience, and Full Site Editing
marktimemedia
0
430
4 Signs Your Business is Dying
shpigford
187
22k
The Hidden Cost of Media on the Web [PixelPalooza 2025]
tammyeverts
2
230
XXLCSS - How to scale CSS and keep your sanity
sugarenia
249
1.3M
The Spectacular Lies of Maps
axbom
PRO
1
570
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
Keith and Marios Guide to Fast Websites
keithpitt
413
23k
Information Architects: The Missing Link in Design Systems
soysaucechin
0
810
Build your cross-platform service in a week with App Engine
jlugia
234
18k
Transcript
Refactoring Oli Wood @coldclimate
What How Tools When
2,300 lines single file no classes 2 years old
"too important to risk breaking it"
"make it do this..."
what
replacing what is there with something new
that does exactly the same thing
same functionality
...faster
...securer
...extendable
...maintainabler
...more better
how
work out what it actually does (you think)
...high level
fits into a couple of paragraphs
...low level
function by function docblock it
find out what it actually does
including the bits everybody forgot
document its API/interface/what ever
unit tests*
Redesign it
high level logical grouping
Class structure
...think design patterns (maybe)
work out where you are going
...and get there step at a time
...nail the bit you're working on
...don't have too many balls in the air
...#TODO this thing you will forget
...#SHOULDDO ace thing you might do later
...keep running the tests
...and stop at 80%
tools
sublime text
redacted
grep -Rin
phpunit
Selenium
ghetto tests (curl > Apache logs > *nix > diff)
code formatters
php codesniffer
php coding standards fixer
when
Refactoring is a good sign you're thinking about the code
...constant refactoring is geek circle jerk
...man up and live with it
...when it stops you doing something more important
...when you know what you're doing
...once the cost of not doing it out weighs that
of doing it
...when can't stand it any more
16 files object orientated does exactly the same thing
2 new modules Several £k income Multi-developer
A confession
FIN