cdinto the root folder of a Rails app. (I usually open a second command line tab to do this, while leaving my
rails serverrunning in the first one.)
rails console, or
rails cfor short. This will launch a new (text-only) app.
2.x.x :001 >or
"on a string or
]on an array). To reset and get out of the weird state, press Ctrl+C. Then press the Up arrow to recover your last command, and fix the mistake.
exitand press return to shut down that program and return to the regular old command prompt. Or just close that command line tab.
.rbfile. Have fun!