DEV Community

Discussion on: dev.to open source help/discussion thread (v0)

Collapse
 
itsasine profile image
ItsASine (Kayla)

Does anyone know how to update the built-in version of ruby on Mac?

➜  ~ ruby -v
ruby 2.3.7p456 (2018-03-28 revision 63024) [universal.x86_64-darwin17]
➜  ~ /usr/local/Cellar/ruby/2.5.1/bin/ruby -v
ruby 2.5.1p57 (2018-03-29 revision 63029) [x86_64-darwin17]

I ended up getting around it by using RubyMine and telling it to use the brew version for the dev.to environment, and then I set up the bin scripts as run configurations.

Since I had ruby 2.5.1 installed, I wasn't terribly inclined to download RVM just so it could download its own version of ruby, too. I just don't think this was the most optimal way of fixing my version issues.

(And as someone who never used postgressql before, that part was not intuative at all... but I have no clue how to fix that in the docs, since I was bumbling my way through it)

Collapse
 
rhymes profile image
rhymes

I use RVM because I have different projects using different versions of Ruby and it's useful for that:

➜  ~ rvm list
   ruby-2.3.0 [ x86_64 ]
   ruby-2.4.3 [ x86_64 ]
=* ruby-2.5.1 [ x86_64 ]

# => - current
# =* - current && default
#  * - default

(And as someone who never used postgressql before, that part was not intuative at all... but I have no clue how to fix that in the docs, since I was bumbling my way through it)

Can you please articulate what issues did you have? I think it's very important because a difficult onboarding can be a turn off for first contributors. Thank you!

Collapse
 
itsasine profile image
ItsASine (Kayla)

My issue was trying to figure out how to articulate it late at night ;)

I think the issues started with completely blowing past the hey you need to install this stuff first section of the README and just starting to get the local build working with stuff like api keys and bundle install. And since I was having issues with the ruby version, I was inclined to think all my issues were around ruby rather than the db.

The biggest thing after needing it installed was needing to have it run before running anything. The installation was lumped with installing things like bundle and yarn which are more hands-off, so it wasn't clear that after installing the prereqs, I should actually start the db and that it wasn't handled in the bin scripts like everything else.

Then I wanted to actually see what was in the db, so I hunted through the configs and internet to see how to find the settings of the db that's created to connect to it within RubyMine.

It wasn't anything really hard or missing, just stuff that wasn't obvious as someone not in the stack.

Collapse
 
andy profile image
Andy Zhao (he/him)

(And as someone who never used postgressql before, that part was not intuative at all...

Ah gotcha, we'll shore that up for the next iteration. What sort of issues are you having right now with it?

Does anyone know how to update the built-in version of ruby on Mac?

Are you using a Ruby version manager? You probably have rbenv or rvm installed.

Collapse
 
itsasine profile image
ItsASine (Kayla)

Are you using a Ruby version manager?

As far as I know, I have not because I'm not a Rubyish person, but I can check once I get home. I knew I brew installed it and would have installed it way back when for brew (since I'm pretty sure brew runs on ruby) but otherwise I don't recall ever doing anything with ruby.

What sort of issues are you having right now with it?

Right now, nothing, since I was eventually able to get local dev.to up and running to get my screenshots for my PR :) Originally, though, since I was only installing it to use dev.to, I didn't:

  1. have it installed (ended up installing it outside of the recommended path since I was trying to solve ruby errors rather than continue reading the readme and find what I skipped over)
  2. have it running (lots of googling eventually found me to where a blog somewhere listed the command to run it)
  3. or how to access it (I loved the seed data scripts but wanted to add a user with specific data to hit my cases... I ended up setting up Github integration to use myself, but eventually figured out how to list known databases and then I could use RubyMine's built-in db handling to modify local data)

Like, reading the section of hey install this stuff didn't really click with me to actually run the database and that it was not a part of the bin scripts.

Thread Thread
 
andy profile image
Andy Zhao (he/him)

Ah gotcha, sorry that wasn't clear! We'll definitely update the instructions for the prerequisites.

And yep, let me know if you still have issues with your Ruby, or anything else really. 🙂