Runing ruby on rails code from console?

Discussion in 'Ruby' started by Jonathan Heinen, May 24, 2006.

  1. Hi,

    if I want to start the code of a controller making use of activrecords
    and other rails stuff, is there any possibilitie to start this script
    from the consol or by a cron job?

    Jonathan
     
    Jonathan Heinen, May 24, 2006
    #1
    1. Advertising

  2. Jonathan Heinen

    Psychotron Guest

    Jonathan Heinen <> wrote:

    > Hi,
    >
    > if I want to start the code of a controller making use of activrecords
    > and other rails stuff, is there any possibilitie to start this script
    > from the consol or by a cron job?


    I think the script runner is your friend

    ..script/runner -e production "Model.do_something"

    --
    Psychotron - http://www.en0.org
    "The only thing that I know is that I don't know anything" -Socrates
     
    Psychotron, May 24, 2006
    #2
    1. Advertising

  3. Psychotron schrieb:
    > [...]
    > .script/runner -e production "Model.do_something"
    >


    Thank you that is perfektly what i want! =)

    Jonathan
     
    Jonathan Heinen, May 25, 2006
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Nikolay Petrov

    Runing Client-side code

    Nikolay Petrov, Mar 22, 2005, in forum: ASP .Net
    Replies:
    4
    Views:
    620
    Jason Mauss
    Mar 24, 2005
  2. mg
    Replies:
    0
    Views:
    126
  3. Alex Martin Ugalde

    Runing ruby scripts on multiprocesors

    Alex Martin Ugalde, Oct 26, 2004, in forum: Ruby
    Replies:
    2
    Views:
    83
    Alex Martin Ugalde
    Oct 27, 2004
  4. Replies:
    6
    Views:
    187
    Michael Campbell
    Mar 17, 2005
  5. sonet
    Replies:
    6
    Views:
    183
    J├╝rgen Exner
    Jun 17, 2007
Loading...

Share This Page