ºÝºÝߣ
Submit Search
Upgrading rails-it-is-a-good-time-to-refactor-your-code-en-upgrading-rails-it-is-a-good-time-to-refactor-your-code
?
0 likes
?
511 views
•Fçù ÅË
Follow
1 of 40
Download now
Download to read offline
More Related Content
Upgrading rails-it-is-a-good-time-to-refactor-your-code-en-upgrading-rails-it-is-a-good-time-to-refactor-your-code
1.
Upgrading?Rails??It?is?a? good?time?to?refactor? your?code P.S.V.R Powered?by?Rabbit?2.1.2
2.
Rails?4.1?was?released? last?week! 1/39
3.
Why?is?it?a?good?time?to? refactor?your?code??(1) Trust?me:?if?you?had?time?for? upgrading,?you?would?have?time?for? refactoring 2/39
4.
Why?is?it?a?good?time?to? refactor?your?code??(2) ???????????????????????????????????????? ??????????????????????????????????????????? ???????? ??????????????????????????????????????????????????????????????????? some?upgraded?behaviors?require? refactoring?after?all 3/39
5.
Why?is?it?a?good?time?to? refactor?your?code??(3) ??????????????????????????????????? ????????? ?????????????????? ??????????????????????????? ???????????????????????????????? ?????????????????????????????????????????????????????????? ????????????????????????????????????????????????????? You?wan?to?implement?old?functions?via? new?features 4/39
6.
Roadmap ¢ñ.?Community?Guidelines ¢ò.?Code?coverage ¢ó.?Dependencies?updating ¢ô.?Density?of?Comments ¢õ.?Cyclomatic?complexity ¢ö.?Static?code?analyzer ¢÷.?Commit?messages 5/39
7.
¢ñ.?Community? Guidelines?(1) ruby-style-guide A?community-driven?Ruby?coding?style? guide https://github.com/bbatsov/ruby-style- guide 6/39
8.
¢ñ.?Community? Guidelines?(2) ex.?Comments?section 7/39
9.
¢ñ.?Community? Guidelines?(3) rails-style-guide A?community-driven?Rails?3?&?4?style? guide https://github.com/bbatsov/rails-style- guide 8/39
10.
¢ñ.?Community? Guidelines?(4) ex.?Routing?section 9/39
11.
¢ò.?Code?coverage?(1) simplecov Code?coverage?for?Ruby?1.9+?with?a? powerful?con?guration?library?and? automatic?merging?of?coverage?across? test?suites gem?install?simplecov 10/39
12.
¢ò.?Code?coverage?(2) 11/39
13.
¢ò.?Code?coverage?(3) coveralls.io https://coveralls.io/ gem??coveralls?,?require:?false 12/39
14.
¢ò.?Code?coverage?(4) 13/39
15.
¢ó.?Dependencies? updating?(1) gemnasium https://gemnasium.com/ 14/39
16.
¢ó.?Dependencies? updating?(2) 15/39
17.
¢ô.?Density?of? Comments?(1) cf.?http://sta?.unak.is/andy/ StaticAnalysis0809/metrics/dc.html 16/39
18.
¢ô.?Density?of? Comments?(2) inch Documentation?measurement?tool?for? Ruby,?based?on?YARD. gem?install?inch 17/39
19.
¢ô.?Density?of? Comments?(3) 18/39
20.
¢ô.?Density?of? Comments?(4) inch-pages https://github.com/rrrene/inch-pages 19/39
21.
¢ô.?Density?of? Comments?(5) 20/39
22.
¢õ.?Cyclomatic? complexity?(1) developed?by?Thomas?J.?McCabe,?Sr.?in? 1976 For?this?strongly?connected?control? ?ow?graph,?Cyclomatic?complexity?=?3? is?the?number?of?linearly?independent? cycles?that?exist?in?the?graph,?i.e.?those? cycles?that?do?not?contain?other?cycles? within?themselves. 21/39
23.
¢õ.?Cyclomatic? complexity?(2) 22/39
24.
¢õ.?Cyclomatic? complexity?(3) ??????? ??????????? ??? ex.?Cyclomatic?complexity?=?1 23/39
25.
¢õ.?Cyclomatic? complexity?(4) ?????????????????? ???????????????????????? ??? ex.?Cyclomatic?complexity?=?2 24/39
26.
¢õ.?Cyclomatic? complexity?(5) ??????????????????????????????? ??????????????????????????????????????? ??? ex.?Cyclomatic?complexity?=?3 25/39
27.
¢õ.?Cyclomatic? complexity?(6) ???????????? ?????????? ??????????????????????????????? ????????????????????????????????? ????????????????????????????????????? ??????????????????????????????????? ??????????????????????????????? ??????????????????????????????????? ??????????????????????????????? ????? ??? ex.?Cyclomatic?complexity?=?8 26/39
28.
¢õ.?Cyclomatic? complexity?(7?-?before) ???????????????????????? ????????????? ????????????????????????????????????????????????????????? ?????????????????????????????????????? ???????????????????????????????????? ??????????????????????? ?????????????????????????????????????????????? ????????????????????? ????????????????????????????? ????????????????????????????????? ?????????????????????????????????? ???????????????????????????????????????? ????????????????????????????????? ???????????????????????????????????????????????????? ??????????????????????????????????? ??????????????????????????????????? ?????????????????????????????????????????????????? ????????????????????????????????????????????????????????????? ???????????????????????????? ????? ????? ????????????? ??? 27/39
29.
¢õ.?Cyclomatic? complexity?(8?-?after) ?????????????????????????????????????????????????????? ???????????????????????? ???????????????????????????????????????????????????????? ???????????????????? ???????????????????????????????????????????? ??? 28/39
30.
¢õ.?Cyclomatic? complexity?(9?-?after) ???????????????? ??????????????????? ??????????????????????????? ????????????????????????????????????????????????????????????? ???????????????????????????????? ?????????????????????????????????????? ?????????????????????????????????????????????????????????????????????????? ????????????????????????????????? ???????????????????????????????????????????????????????????? ??? ?????? ??? 29/39
31.
¢ö.?Static?code?analyzer? (1) rubocop gem?install?rubocop rubocop?-R?>?rubocop.txt 30/39
32.
¢ö.?Static?code?analyzer? (2) 31/39
33.
¢ö.?Static?code?analyzer? (3) codeclimate https://codeclimate.com/ 32/39
34.
¢ö.?Static?code?analyzer? (4) 33/39
35.
¢÷.?Commit?messages? (1) good?commit?message?example 34/39
36.
¢÷.?Commit?messages? (2) bad?commit?message?examples 35/39
37.
¢÷.?Commit?messages? (3) bad?commit?message?examples 36/39
38.
¢÷.?Commit?messages? (4) bad?commit?message?examples 37/39
39.
How?to?write?good? commit?messages? Use?English Use?the?imperative,?present?tense:? ¡°change¡±,?not?¡°changed¡±?or?¡°changes¡±;? ¡°Fix?bug#1234¡±?is?better?than?¡°Fixed? bug?#1234¡± Use?50-char?title?and?Use?72-character? columns?for?word-wrapping. Read?more:?https://github.com/ torvalds/linux/ pull/17#issuecomment-5654674 38/39
40.
Download?the?slides https://github.com/pmq20 39/39Powered?by?Rabbit?2.1.2
Download