cordova-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "John M. Wargo" <jwarg...@gmail.com>
Subject Re: Node Hook?
Date Tue, 23 Sep 2014 16:25:45 GMT
Node is absolutely on the path - the cordova command works and I can run node test.js without
error.

I'll check the line endings. Thanks.

On 9/22/2014 1:01 PM, Dick Van den Brink wrote:
> I'm still on 3.4 so not sure about 3.5 but I know it doesnt work when you use windows
newlines. Can you change it to unix newlines and check if that works? (+ is node in your path?)
>
> Would expect a different error though...
>
> Sent from my Windows Phone
> ________________________________
> From: John M. Wargo<mailto:jwargo23@gmail.com>
> Sent: ‎22/‎09/‎2014 18:47
> To: Cordova Dev<mailto:dev@cordova.apache.org>
> Subject: Node Hook?
>
> Is there anything special I have to do to run a node app as a hook on Windows?
>
> I was experimenting with this yesterday on Cordova 3.5, and when I have the following
hook as a before prepare:
>
>       #! /usr/bin/env node
>       console.log('this is a node module');
>
> I get the following error:
>
>       The system cannot find the path specified.
>       Hook failed with error code 1: C:\Users\jwargo\dev\lunchmenu\hooks\before_prepare\test.js
>
> So it's seeing the hook and not 'finding' it?
>
> On Stack Overflow, the suggestion was to remove the first line and just have the console
line:
>
>       console.log('this is a node module');
>
> When I do that, I get a different error:
>
>       Hook failed with error code Unknown system errno 193: C:\Users\jwargo\dev\lunchmenu\hooks\before_prepare\test.js
>
> --
> John M. Wargo
> @johnwargo <http://twitter.com/johnwargo>
> www.johnwargo.com <http://www.johnwargo.com>
> ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message