puts statement in ruby automatically adds a new line, how do I avoid it?
Use print instead.
You may want to follow it up by STDOUT.flush.
Also, you'll need to append "\r" at end of line to indicate "carriage return" and do next print at beginning of current line
$stdout.sync = true
100.times do
print "."
sleep 1
end
"How can I use “puts” to the console without a line break in ruby on rails?"