How to run script from command line?
I have a script in my lib/config/my_script.rb
which make a synchronization from MAIN database to m开发者_StackOverflow社区y Database.
How i can run it from command line? And it will be working?
ruby my_script.rb
I also wanted to provide a Ruby quick reference guide that will give you additional information on command line arguments for the ruby command as well as a wealth of other information on Ruby.
Ruby Quick Reference Guide: http://www.zenspider.com/Languages/Ruby/QuickRef.html
ruby lib/config/my_script.rb
or
./lib/config/my_script.rb
精彩评论