Help Needed with Ruby Versions and Installation

Hello, I have recently installed Jekyll on my (Intel) Mac, and was following these instructions: Jekyll on macOS | Jekyll • Simple, blog-aware, static sites

Note: I installed Xcode and its command line tools first, since a couple other sources made it seem like I should do that as well…

But following the instructions linked above, I installed the latest stable version of Ruby. And when I do ruby -v, it shows as ruby 3.1.2p20 (as per the instructions).

So far so good, but now things get confusing because of the existing Ruby version on my Mac…

So I followed the commands to configure my (zsh) shell to automatically use chruby, as follows:

  1. echo "source $(brew --prefix)/opt/chruby/share/chruby/chruby.sh" >> ~/.zshrc
  2. echo "source $(brew --prefix)/opt/chruby/share/chruby/auto.sh" >> ~/.zshrc
  3. echo "chruby ruby-3.1.2" >> ~/.zshrc

I then proceeded to install Jekyll, and that appeared to work just fine. However, when I do brew config, one of the outputted lines is:
Homebrew Ruby: 2.6.10 => /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/bin/ruby

Which makes it seem I have the older version of Ruby selected here, and I’m not sure if that’s the one I want?

Also, when I run brew doctor, it says my Git version is old (2.10.1) and I should upgrade it. So I did with their command (brew upgrade git), and now when I run that command again it says that git 2.38.1 is installed. However, when I run git --version, it still says version 2.10.1. So that is a contradiction that I can’t figure out how to solve …

So basically I just need some help to finish this off, so everything is correct and I know for sure which Ruby version I should be using and how to select that version.

Thanks for your help,
Jim