rails_best_practices

https://github.com/flyerhzm/rails_best_practices

Ruby

a code metric tool for rails projects

RailsBestPractices::Reviews::IsolateSeedDataReview#remember_new_variable

check assignment node,
if the right vavlue is a method_add_arg node with message "new",
then remember the left value as new variable.

Source | Google | Stack overflow

Edit

git clone [email protected]:flyerhzm/rails_best_practices.git

cd rails_best_practices

open lib/rails_best_practices/reviews/isolate_seed_data_review.rb

Contribute

# Make a new branch

git checkout -b -your-name--update-docs-RailsBestPractices--Reviews--IsolateSeedDataReview-remember_new_variable-for-pr


# Commit to git

git add lib/rails_best_practices/reviews/isolate_seed_data_review.rbgit commit -m "better docs for RailsBestPractices::Reviews::IsolateSeedDataReview#remember_new_variable"


# Open pull request

gem install hub # on a mac you can `brew install hub`

hub fork

git push <your name> -your-name--update-docs-RailsBestPractices--Reviews--IsolateSeedDataReview-remember_new_variable-for-pr

hub pull-request


# Celebrate!