How to introduce RuboCop and integrate into Jenkins

How to introduce RuboCop and integrate into Jenkins

How to introduce RuboCop and integrate with Jenkins in your project.
M3 Tech Talk #13 2013/11/08 #m3dev

509e5167fdb3871d6b6e045e34a3e019?s=128

Takayuki Matsubara

November 08, 2013
Tweet

Transcript

  1. )PXUPJOUSPEVDF 3VCP$PQBOEJOUFHSBUF XJUI+FOLJOT .5FDI5BML . *OD BTBLVTBSC 5XJUUFS!NBHF (JU)VCNBHFEFW #SFBEDSVNCMF

  2. )3὎)3 !.)

  3. 3VCP$PQ IUUQTHJUIVCDPNCCBUTPWSVCPDPQ

  4. 5IF3VCZ4UZMF(VJEF IUUQTHJUIVCDPNCCBUTPWSVCZTUZMFHVJEF

  5. HFNJSVCPDPQ DE:063@130+&$5@%*3 SVCPDPQ

  6. Offences: test.rb:1:5: C: Use snake_case for methods and variables. def

    badName ^^^^^^^ test.rb:2:3: C: Favor modifier if/unless usage when you have a single-line body. Another good alternative is the usage of control flow &&/||. if something ^^ test.rb:4:5: W: end at 4, 4 is not aligned with if at 2, 2 end ^^^ 1 file inspected, 3 offences detected IUUQTHJUIVCDPNCCBUTPWSVCPDPQ
  7. 0WFS P⒎FODFT JOPVSQSPKFDU

  8. :PVDBOSFEVDF XJUIDPOpH

  9. SVCPDPQZNM

  10. &9".1-& IUUQTHJUIVCDPNNBHFEFWCSFBEDSVNCMF CMPCNBTUFSSVCPDPQZNM

  11. SVCPDPQa BVUPHFODPOpH SVCPDPQUPEPZNM

  12. JOIFSJU@GSPN SVCPDPQUPEPZNM

  13. *OUFHSBUF3VCP$PQ XJUI+FOLJOT

  14. 3VCP$PQ$IFDLTUZMF 'PSNBUUFS IUUQTHJUIVCDPNFJUPCBMMSVCPDPQ DIFDLTUZMF@GPSNBUUFS

  15. /FFE"+FOLJOT 1MVHJO7JPMBUJPOT IUUQTXJLJKFOLJOTDJPSHEJTQMBZ+&/,*/4 7JPMBUJPOT

  16. CVOEMFFYFDSVCPDPQa SFRVJSFSVCPDPQGPSNBUUFSDIFDLTUZMF@GPSNBUUFSa 3a GPSNBU3VCPDPQ'PSNBUUFS$IFDLTUZMF'PSNBUUFSa PVUUNQDIFDLTUZMFYNM

  17. None
  18. 6TFGVM0QUJPO rubocop --format offences (87) Documentation (12) DotPosition (8) AvoidGlobalVars

    (7) EmptyLines (6) AssignmentInCondition (4) Blocks (4) CommentAnnotation (3) BlockAlignment (1) IndentationWidth (1) AvoidPerlBackrefs (1) ColonMethodCall
  19. FOE