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
PhpStormで重複コードを一瞬で見つける
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Yuichi Sugiyama
PRO
November 27, 2019
Technology
940
2
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
PhpStormで重複コードを一瞬で見つける
第144回PHP勉強会の発表内容です
Yuichi Sugiyama
PRO
November 27, 2019
More Decks by Yuichi Sugiyama
See All by Yuichi Sugiyama
20年以上続く PHP 大規模プロダクトを Kubernetes へ ── クラウド基盤刷新プロジェクトの4年間
oogfranz
PRO
0
470
サイボウズ と Garoon と The PHP Foundation と 私 / Cybozu and Garoon and The PHP Foundation and me
oogfranz
PRO
1
620
可能な限り確実にmkdirを成功させるには / Make mkdir
oogfranz
PRO
0
760
サイボウズ #Garoon 開発チームの 「 完成度低いの歓迎LT大会 」 PHPerKaigi出張版 / Low quality LT in PHPerKaigi 2023
oogfranz
PRO
0
780
20年ものの巨大プロダクトをKubernetesに移行している話 後日談/Garoon on Kubernetes after talk
oogfranz
PRO
0
660
20年ものの巨大プロダクトをKubernetesに移行している話/Garoon on Kubernetes
oogfranz
PRO
0
580
PHPアプリケーションだってモニタリングしたい / Monitoring PHP application
oogfranz
PRO
1
690
効果的な静的解析の CI導入パターンを求めて / Great static analysis with CI
oogfranz
PRO
3
4.1k
Dev-meets-Ops
oogfranz
PRO
1
1.1k
Other Decks in Technology
See All in Technology
2026-09-09 【sigma_ucj#1】Sigma を IaC 管理したい! / IaC for Sigma
civitaspo
0
110
Deploying a Full-Stack Bun-Native Framework on Cloudflare Workers
7nohe
0
130
AI時代のAPI品質を支えるガードレール / API Guardrails for API quality in the AI era
yokawasa
1
210
20260906 「AWS運用入門」著者が教える、運用業務への生成AI活用入門
masaruogura
0
260
DEFCON34-Write-up_HYCu-MYCu
daikiokazaki
0
140
2026_devsumi_ozono.pdf
o3
2
330
Where Is JetBrains AI Heading- — Central CLI, Air Alpha, and the Agentic Development Stack
x5gtrn
PRO
0
150
AI活用の現在地、 ちゃんと見えてますか?/XPfest-2026
visional_engineering_and_design
0
180
KPIだけでは評価できないプロダクトが考えるべき Evalsという第二の評価系 / Beyond KPIs: Evals as a Second Evaluation Framework for Products #PdEConf
aki_iinuma
4
3.9k
Driving AI Adoption Using In-House GPUs to Serve Qwen
po3rin
2
480
例外の正しい扱い方 そのエラー try-catchして大丈夫?
jinwatanabe
3
450
AI時代に顧客へ最速で価値を 届けるための試行錯誤 〜「AI × マネジメント」領域におけるmentoのケース〜
posterkeisuke
0
110
Featured
See All Featured
Become a Pro
speakerdeck
PRO
31
6.2k
Navigating the moral maze — ethical principles for Al-driven product design
skipperchong
2
520
GitHub's CSS Performance
jonrohan
1033
470k
Conquering PDFs: document understanding beyond plain text
inesmontani
PRO
4
3k
Designing for humans not robots
tammielis
254
26k
Jess Joyce - The Pitfalls of Following Frameworks
techseoconnect
PRO
1
410
Effective software design: The role of men in debugging patriarchy in IT @ Voxxed Days AMS
baasie
0
510
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
56
3.5k
The Art of Programming - Codeland 2020
erikaheidi
57
14k
WENDY [Excerpt]
tessaabrams
13
39k
The Mindset for Success: Future Career Progression
greggifford
PRO
0
490
Bridging the Design Gap: How Collaborative Modelling removes blockers to flow between stakeholders and teams @FastFlow conf
baasie
0
690
Transcript
PhpStormͰ ॏෳίʔυΛ ҰॠͰݟ͚ͭΔ Cybozu ਿࢁ༞Ұ @oogFranz
Who am I • ਿࢁ ༞Ұ @oogFranz • αΠϘζ5ΤϯδχΞ •
େاۀ͚άϧʔϓΣΞGaroon࡞ͬͯΔʢPHP 7) • ෳۀδϟζϛϡʔδγϟϯ@MASHݭָஂ
PHP ConferenceͰ·͢ʂ
ॏෳίʔυ͋Γ·ͤΜ͔ʁ • ಈ͘ίʔυ͕ίϐϖ͞Ε͍ͯΔ • ෆ۩߹͕͋ͬͨΒॏෳίʔυશͯमਖ਼͕ඞཁ • ػೳՃ͕͋ͬͨΒॏෳίʔυશͯରԠ͕ඞཁ • ίϐϖίʔυΛݟ͚ͭͯॏෳΛऔΓআ͖͍ͨ
ॏෳίʔυ͋Γ·ͤΜ͔ʁ • ಈ͘ίʔυ͕ίϐϖ͞Ε͍ͯΔ • ෆ۩߹͕͋ͬͨΒॏෳίʔυશͯमਖ਼͕ඞཁ • ػೳՃ͕͋ͬͨΒॏෳίʔυશͯରԠ͕ඞཁ • ίϐϖίʔυΛݟ͚ͭͯॏෳΛऔΓআ͖͍ͨ PhpStormͰ؆୯ʹݟ͚ͭΑ͏ʂ
Γ͔ͨ 1. ·ͣPhpStorm 2019.2ΛΠϯετʔϧ͠·͢
Γ͔ͨ 1. ·ͣPhpStorm 2019.2ΛΠϯετʔϧ͠·͢ Ҏ্Ͱ͢
DEMO https://github.com/oogFranz/duplicate-code-test
ॏෳ͕Weak WarningͰ
Diff viewerͰॏෳ۩߹Λ֬ೝ
ม໊ͷҧ͍ݕग़
໊ؔϦςϥϧͷҧ͍ݕग़ • Editor > Duplicates ͔Βཁઃఆมߋ
ΑΓෳࡶͳॏෳɺ୯७ͳॏෳΛݟ͚ͭΔ • unit ͱ͍͏୯ҐΛಈ͔͢͜ͱͰॏෳͷݟ͔ͭΔ۩߹Λมߋ • units = 2 * number
of statements + number of expressions • σϑΥϧτ45ɻׂͱదͳͳͷͰ߹Θͳ͔ͬͨΒมߋ͢Δɻ • ݴޠ͝ͱʹઃఆՄೳ
ॏෳίʔυΛશ෦ݟ͚ͭΔ • Run Inspection By NameΛ࣮ߦ • Mac ͳΒ ”⌃⌥⇧I”
ɺWinͳΒ ”Ctrl+Shift+Alt+I” • “Duplicated code fragment” Λೖྗ࣮ͯ͠ߦ