Change tempfile name to ripl-editor.
Use the .rb extension, for Ruby syntax highlighting.
Use less regexp.
Be nice to Windows users and use $/
give cred