| Author |
cygwin shell scripts
|
|
| prashant 2006-11-24, 7:24 am |
| I have installed cygwin on my computer... and am looking to run shell
scripts with it...
I run the command ./run.sh (shell script)
But the only thing is get is
: command not found
: command not found
: command not found
: command not found
: command not found
: command not found
Guess the compiler is not able to look for the commands in the correct
directory
i have checked the PATH variables
and it has the following things included in it...
/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin
I guess this is enough for the compiler to look for shell runtime
environment
| |
| Bill Marcum 2006-11-24, 7:24 am |
| On 24 Nov 2006 01:53:13 -0800, prashant
<b.prashant@gmail.com> wrote:
> I have installed cygwin on my computer... and am looking to run shell
> scripts with it...
>
> I run the command ./run.sh (shell script)
>
> But the only thing is get is
>: command not found
>: command not found
>: command not found
>: command not found
>: command not found
>: command not found
>
> Guess the compiler is not able to look for the commands in the correct
> directory
The shell is not a compiler. Those error messages look as if they might
have been caused by a script edited with Notepad or some other editor
which adds a CR character to the end of each line.
--
Progress was all right. Only it went on too long.
-- James Thurber
| |
| prashant 2006-11-24, 1:21 pm |
| Yes!!!
Thanks... thats was exactly the problem
between notepad format and the unix format
Bill Marcum wrote:
> On 24 Nov 2006 01:53:13 -0800, prashant
> <b.prashant@gmail.com> wrote:
>
> The shell is not a compiler. Those error messages look as if they might
> have been caused by a script edited with Notepad or some other editor
> which adds a CR character to the end of each line.
>
>
>
> --
> Progress was all right. Only it went on too long.
> -- James Thurber
| |
| William 2006-11-27, 7:23 pm |
| "prashant" <b.prashant@gmail.com> wrote in message
news:1164379505.137648.315560@h54g2000cwb.googlegroups.com...
> Yes!!!
>
> Thanks... thats was exactly the problem
> between notepad format and the unix format
When you install cygwin you have an option to choose
DOS-style line endings for text files. I would only
recommend that if you must use an editor that insists
on putting in the CR/LF pair. Better to keep things
Unix-like, just as you are doing, in my opinion.
(You might want to look for an editor that not only
knows unix but also does syntax highlighting for
shell scripts - I use UltraEdit, but there are
others.)
By the way, if you have to process files with CR/LF
end of line markers, you can add the CR to your IFS
value and your scripts will happily eat it as just
another whitespace delimiter.
-Wm
|
|
|
|