Ruby - Getting Started (Addendum)
I am finding some issues with the getting started guide that is available at: Ruby on Rails: Getting Started. Here are some clarifications.
Section 3.1
The guide assumes a database is installed. This should not be assumed. I used MySQL which is very easy to install. You should use the current stable build, if possible. 8.4 was the version at the time of writing.
Installation instructions for linux or wsl can me found here: Installing MySQL on Linux
Section 3.2
When creating a new Rails app, use the command: rails new store -d mysql
You can replace 'mysql' with a different database if you installed something other than MySQL. This will ensure that your project will function for the rest of the guide.
Section 7.1
For instantiation of the new Product record, only use the command: product = Product.new(name: "T-Shirt")
Anytime you see '=>', do not include the line as it is a result, not a command.
The rest of the text in the box is the result and will drop you into a special console prompt that is an '*'. If you end up with the console * prompt, simply press Ctrl-c to return the the normal > prompt.
Section 9.3
You only need the code snippet: get "/products", to: "products#index"
You do not need the rest. Just place the snippet in your route file below the line that starts with '# Define your app...'
I would recommend leaving everything else in place for reference.