@StatelessCode
  @StatelessCode
Stateless Code | Update Ruby then Add RuboCop to a Rails Project @StatelessCode | Uploaded September 2022 | Updated October 2024, 3 hours ago.
"Dead or alive, you're coming with me!"

Unlike government police, RuboCop provides for enforcement of a voluntary and configurable set of standards. Code linting can improve the health of your codebase, help you and your collaborators maintain your project more easily, and identify ambiguous or buggy code.

In this 2nd video in the NerdDice.com series, we add RuboCop to our Gemfile, and adapt an existing .rubocop.yml file from the user home directory and add some additional configuration updates and exclusions.

Before we do that, we fix an oversight from the previous video where the project was setup with an outdated version of Ruby.

This video covers:
00:00:12 Introduction and recap of previous video
00:01:07 Upgrade Ruby from 3.1.0 to 3.1.2.
00:10:00 Update Gemfile with relevant RuboCop gems
00:11:37 Copy and start adapting existing rubocop.yml from the home directory to the project
00:12:27 Run bundle install, attempt to run RuboCop, fix initial errors to get initial set of offenses
00:13:58 Disable frozen string literal cop
00:16:00 Review remiaining offenses and start adding exclusions for some of the system generated files
00:22:56 Review and start clearing RuboCop warnings by enabling new cops, removing repeated config, and adding more exclusions
00:30:57 Commit, merge, update project

#ruby #rails7 #rails #rubyonrails #rubygems #codecast #screencast #github #opensource #minitest #TDD #agile #NerdDice #DnD #roleplaying #softwaredevelopment #learntocode #rubocop

See other related StatelessCode videos::
- Install RVM and Ruby with Troubleshooting youtu.be/h-JBRJH8W7A
- RuboCop Install and Initial Setup youtu.be/dKpiJhA19yg
- Add RuboCop to nerd_dice Gem youtu.be/Iz_Wl-IDL-c

This video is CC0 - No rights reserved. (YouTube doesn't allow this option when publishing.) All code is released under the UNLICENSE. Stateless Code denies the concept of "intellectual property". Copying is not stealing.
Update Ruby then Add RuboCop to a Rails ProjectWrite System Tests for Devise Reconfirm Email and Refactor Shared Code into a Testing ConcernBroadcasting Comments from Conall and Donall #stpatricksday #rails #modalismCodecast: statelesscode.com WordPress 26: Retrospective for Release 2Inkscape 03: Install on Mac, rework SVG from previous videoCodecast: statelesscode.com WordPress 18: Use JavaScript to Add Elements for Tailwind StylingCodecast: Create a RubyGem 68: Implement the First Magic MethodCodecast: statelesscode.com WordPress 15: Release 1 RetrospectiveWrite System Tests for Devise Login and LogoutCodecast: statelesscode.com WordPress 02: Get the Local Dev Environment Up and RunningCodecast: statelesscode.com WordPress 05: Use Tailwind to Style the HeaderCodecast: Getting Started with Rails 7 28: Retrospective for the Series

Update Ruby then Add RuboCop to a Rails Project @StatelessCode

SHARE TO X SHARE TO REDDIT SHARE TO FACEBOOK WALLPAPER