This is the mail archive of the
cygwin
mailing list for the Cygwin project.
RE: How can I run a script?
On 14 January 2008 13:36, Eric Blake wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> According to BB on 1/13/2008 5:41 PM:
>> can login to a shell from windows and run commands but how do I create a
>> script
>
> A script is just a file containing the commands that you would have run
> from the shell, optionally prefixed by something like a #!/bin/sh line to
> specify the intepreter of those commands.
It might help to chmod it +x if it doesn't "just work" (although that should
only be necessary under fairly rare circumstances).
Also if you use a windows-based editor like notepad or wordpad (write),
you'll need to run "d2u" on the file to convert the line-endings from
DOS-style CR/LF to unix-style LF-only before it'll work correctly.
cheers,
DaveK
--
Can't think of a witty .sigline today....
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/