Forum: Ruby ruby cmd prompt doesnt work

A9bef332e140eb6167b65ff222bd6b8d?d=identicon&s=25 Kamil Mila (kamilosusa)
on 2017-01-29 21:36
so as far as I know to start a .rb programm I have to type ruby xy.rb in
the cmd but it doesnt recognize ruby as a command so I cant open it.
someone have an idea why that is?
4828d528e2e46f7c8160c336eb332836?d=identicon&s=25 Robert Heiler (shevegen)
on 2017-01-30 11:50
Are you on windows?

On Linux it is very simple, you must install ruby. Perhaps it is already
available.

You need to give some more information, how did you install ruby?

Btw, "ruby xy.rb" won't open it per se, it will execute/evaluate the
content of that .rb file.
A9bef332e140eb6167b65ff222bd6b8d?d=identicon&s=25 Kamil Mila (kamilosusa)
on 2017-01-30 12:03
Oh you need ruby! I had notepad++ and thought it worked with that as
well.  Sorry I'm a newbie.. But thanks for the answer. Btw would you
recommend installing Linux or should I keep windows till I know some
more?
0fa73332c8e4a3b06ea439fd3f034322?d=identicon&s=25 Ronald Fischer (rovf)
on 2017-01-31 15:42
Kamil Mila wrote in post #1185496:
> so as far as I know to start a .rb programm I have to type ruby xy.rb in
> the cmd but it doesnt recognize ruby as a command so I cant open it.
> someone have an idea why that is?

Maybe ruby is not in your PATH. Either update your path, or type the
full path to ruby every time you invoke it.

BTW, this question is actually unrelated to Ruby. It is the same for
*every* program: Either you have it in your PATH, or you type the path.
Please log in before posting. Registration is free and takes only a minute.
Existing account

NEW: Do you have a Google/GoogleMail, Yahoo or Facebook account? No registration required!
Log in with Google account | Log in with Yahoo account | Log in with Facebook account
No account? Register here.