rails controller generator

To generate a new controller in Ruby on Rails, you can use the following command:

rails generate controller ControllerName

This command will create a new controller file and its associated view and helper files. After running this command, you can start adding actions to the controller, which will handle different requests and render the appropriate views.