Once again the book Practical Ruby for System Administration by Ben Hamou taught me some pretty clever Ruby sysadmin scripting tricks.
One of the scripts that the author used was to automatically populate the path to the Ruby interpreter, update the permissions to 755, and open the script in vi, all during the same process.
I took that same concept and enhanced the script to also auto populate the settings if the scripts is written in Bash, Perl, PHP, or Python.
Download rnew.rb
-Copy rnew.rb to somewhere within your system PATH.
cp rnew.rb /usr/local/bin
-This should give the ability to use rnew.rb from anywhere you’re working on.
rnew.rb koolscript.php
-Happy Hacking :-)