Rails Projects & RubyMine

Today was long but good. I started off by hosting my first study group. Turns some people really do get some coding done on the weekends even if Slack is much quieter. We had a good talk and it was an easy way to start the day.

I got through the Pundit lab which took way longer than I thought it would but that was fine. I didn’t feel like I was beating my head against a well. Just progressing. It felt good to struggle some then overcome.

I started my first Rails Project tonight and was able to get all of the model tests passing. I’ve completely (except for this blog) switched over to RubyMine now and I’m slowing figuring out more and more about it. It’s super powerful and I see a lot of it relies on opening a project in the root folder. All of the labs for Flatiron are in a singular folder so I typically open that one folder full of folders and that throws off most of the features of RubyMine. Too many VCS repos all in one project. Tonight I got tests to run automatically upon code changes. I also realized that RubyMine could generate an image with relationships mapped for my models which is dope. In addition, I started to look at the rubocop linting and was able to remove the block from this map method and use &: instead.

# before
def total
  items.map { |item| item.price }.sum
end

# after rubocop linting
def total
  items.map(&:price).sum
end

I also decided to track my time on each project from now on. However, I completely forgot to start tracking my Rails Projects when I got to it though. Luckily Wakatime saved the day and told me how long I had been working on the project. I’m stoked that I’m on the projects even if it’s a little later in the day than I had planned on. This means I’m almost 100% going to be starting my Rails Portfolio Project tomorrow!

Time spent today: 10:26
Time spent total: 291:53
Lessons completed today: 2
Lessons completed total: 516