Forum: Ruby on Rails "rm public/index.html not recognized."

Posted by wordmystic (Guest)
on 2011-04-01 23:33
(Received via mailing list)
I typed, "rm public/index.html"

Got back, "'rm is not recognized as an internal or external command,
operable program or batch file."

Bruce
Posted by Chris Mear (Guest)
on 2011-04-02 00:26
(Received via mailing list)
On 1 Apr 2011, at 22:31, wordmystic wrote:

> I typed, "rm public/index.html"
>
> Got back, "'rm is not recognized as an internal or external command,
> operable program or batch file."

It sounds like you're on Windows. When you're reading tutorials that 
have UNIX commands in, you'll need to use the Windows equivalent 
instead. 'rm' deleted files, so in the Windows command prompt you'd use 
'del' instead.

The good news is that once you start writing Ruby code and using the 
Rails APIs, they're mostly platform-independent, so you should have less 
trouble with the tutorials.

Chris
Posted by wordmystic (Guest)
on 2011-04-02 01:44
(Received via mailing list)
Actually I took a guess at del and got back:  Invalid switch -
"index.html".
Posted by wordmystic (Guest)
on 2011-04-02 01:56
(Received via mailing list)
But rem worked!
Posted by wordmystic (Guest)
on 2011-04-02 02:28
(Received via mailing list)
OOps!  It's still there, but the rem didn't give me any kind of error
message.
Posted by Michael Pavling (Guest)
on 2011-04-02 09:03
(Received via mailing list)
On 2 April 2011 00:43, wordmystic <bwilsonnow@yahoo.com> wrote:
> Actually I took a guess at del and got back: Invalid switch -
> "index.html".

del public\index.html


If this step is proving a stumble, maybe it would be appropriate to
take some computer foundations classes before trying to learn RoR and
application development? (or if you are very experienced with a
different computer OS, can you do some sort of primer on the
differences in the basics in Windows?)
Posted by Regis Mesquita (Guest)
on 2011-04-02 14:48
(Received via mailing list)
have you already tried , "del public\index.html" ?

--
Regis Mesquita
Sent with Sparrow
Posted by "Régis David Souza Mesquita" <regis@jobdone.com.br (Guest)
on 2011-04-02 14:48
(Received via mailing list)
shouldn't the directory separator be inverted in windows?

del public\index.html

Em 01/04/2011, s 20:43, wordmystic escreveu:
Posted by Regis Mesquita (Guest)
on 2011-04-02 14:49
(Received via mailing list)
Are you on a *nix system( Linux,MacOS X , BSD's)?

If you are , have you already checked the environment variables?

If you aren't , this is a *nix command.

--
Regis Mesquita
Sent with Sparrow
Posted by Jan V. (jan_v)
on 2012-11-30 00:51
You need to "cd public" then "del index.html" windows always have 
problems with path :D
Posted by Hutch C. (hutch_c)
on 2013-04-11 07:30
Thanks Jan - ran into same problem. 'del' for windows (vs. 'rm'), and 
the cd to 'public' did the trick. Very helpful.


Jan V. wrote in post #1087171:
> You need to "cd public" then "del index.html" windows always have
> problems with path :D
Please log in before posting. Registration is free and takes only a minute.
Existing account (Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
No account? Register here.