Howto run a non-app script in console

To save some typing I'd like to create and run any script in the console
window.
By 'any script' I mean non-application related, that is a script that
doos not exist within the application structure.
This would help in exploring stuff without retyping all the time.
Thanks,
Mat

Sorry, I was not too clear in my question.
I ment Rails Console, where I'd like to run scripts that have access
to the application environment but are NOT existing within the app
structure.

Say I'd like to try building and testing a Class that does not exist
(yet) in my application, or try bits of code to see how things work,
without actually modifing any existing application code.

So far, I've been typing and retyping to explore Rails, but it would be
nice to type my tests into a file, so I could build upon my new
experience - and re-run the stuff the next time I get back to it.

Thanks again,
Mat

Matthew Andersen wrote:

Sorry, I was not too clear in my question.
I ment Rails Console, where I'd like to run scripts that have access
to the application environment but are NOT existing within the app
structure.

Say I'd like to try building and testing a Class that does not exist
(yet) in my application, or try bits of code to see how things work,
without actually modifing any existing application code.

So far, I've been typing and retyping to explore Rails, but it would be
nice to type my tests into a file, so I could build upon my new
experience - and re-run the stuff the next time I get back to it.

Thanks again,
Mat

Like this then?

$ script/console

require 'new_test.rb'

=> true

new_test = NewTest.new(whathaveyou)

=> <<What Have You>>

new_test.run

=> true

Stephan

Hi --