Create an add-cats topic branch and commit revisions on it

Switch to the branch we will build upon, main:

git switch main

Create a new topic branch add-cats and switch to it:

git switch -c add-cats

Generate a scaffold for a cat resource:

rails generate scaffold Cat name coat date_of_birth:date

Reset and migrate the database:

rails db:migrate:reset

Stage all your changes and create a new commit:

git add -A
git commit

Add the log message, “Create cat-resource scaffold”, and save the commit: press Ctrl-X (to exit the editor), press Y (to confirm saving the log message), and press Enter (to confirm the location to save to).

Run the gloga command.

Note that the branch add-cats is now ahead of main and parallel with fix-bug and add-dogs in the version history.


⏴ Back Next ⏵