yeoman / yeoman-app

A desktop app that scaffolds projects using Yeoman
988 stars 106 forks source link

Windows support #101

Closed deepu105 closed 8 years ago

deepu105 commented 8 years ago

Hi Guys,

Is the app supported in windows? I followed the getting started instructions application launches but there is nothing but a yeoman image there, build doesnt work as the platform check throws error.

If its not supported yet I would be willing to do some work to get it started

stefanbuck commented 8 years ago

Hi,

limited by my hardware I couldn't test it on Windows. In general it should work. First we should try to get npm start working. Afterwords we can figure out what's wrong with the build script.

Are you getting the "No installed generators found" message like in the screenshot below?

screen shot 2016-02-02 at 12 34 56

What is your console saying? It should be something like that:

App load time: 145ms
YO-Process { action: 'generator:init', args: [] }
APP { event: 'generator:installed-generators', data: [] }
deepu105 commented 8 years ago

Nope no messages, there was only a console error coz of React.render deprecation which i changed and the error was gone but still same behaviour. Container launches and shows the yeoman image alone.

Few other things.

Npm start works it launches as said above Npm build throws platform not supported error, i disabled the check to see if there is any error thrown but nothing. Npm test doesnt work either error says unable to identify the script/test.js task Tried to run the electron commands directly but same result. There was no build folder at all When i launch test from the launched app it throws some assertion error due to unix like path checking for node modules folder

Btw one more thing im running node LTS and npm 3.7.0

Ill upgrade node to 5.x and give it a shot as well On 2 Feb 2016 19:38, "Stefan Buck" notifications@github.com wrote:

Hi,

limited by my hardware I couldn't test it on Windows. In general it should work. First we should try to get npm start working. Afterwords we can figure out what's wrong with the build script.

Are you getting the "No installed generators found" message like in the screenshot below?

[image: screen shot 2016-02-02 at 12 34 56] https://cloud.githubusercontent.com/assets/1393946/12748250/6482164e-c9a9-11e5-9193-f098554394d3.png

What is your console saying? It should be something like that:

App load time: 145ms YO-Process { action: 'generator:init', args: [] } APP { event: 'generator:installed-generators', data: [] }

— Reply to this email directly or view it on GitHub https://github.com/yeoman/yeoman-app/issues/101#issuecomment-178521220.

stefanbuck commented 8 years ago

Yeah updating to node 5.x is definitely a good idea. As I sad before, let us get npm start working before we dive into the build issues. If you see the yeoman images the app boot was successful. So my guess is that something is wrong with the yo child process. To verify that the child process was initialize successfully, please add a log statement before and after this.yoProcess = fork(path.join(__dirname, 'yo', 'yo.js')); in appwindows.js. Please also check if the did-finish-load event was triggered (same file, in the show() method.

deepu105 commented 8 years ago

Ok ill check these today.

I think this could be a great app, coz I try to teach people to use yeoman generators from cli, I'm from the core team of Jhipster many people are still scared of cli and they consider anything to do with cli as complicated so for these kind of people an app like these would be a good place to start with :) On 3 Feb 2016 04:05, "Stefan Buck" notifications@github.com wrote:

Yeah updating to node 5.x is definitely a good idea. As I sad before, let us get npm start working before we dive into the build issues. If you see the yeoman images the app boot was successful. So my guess is that something is wrong with the yo child process. To verify that the child process was initialize successfully, please add a log statement before and after this.yoProcess = fork(path.join(__dirname, 'yo', 'yo.js')); in appwindows.js. Please also check if the did-finish-load event was triggered (same file, in the show() method.

— Reply to this email directly or view it on GitHub https://github.com/yeoman/yeoman-app/issues/101#issuecomment-178790285.

stefanbuck commented 8 years ago

Many thanks for investigating this problem. Make yeoman available for a broader audience, is our goal and the reason why we started this project :wink:

deepu105 commented 8 years ago

OK I have tried below

  1. upgraded to node v5.5.0 & npm v3.7.1 running npm start gives just below, which is same as before node upgrade

image

  1. I tried adding console.log in the appwindow.js it gave the same result as above so out of curiosity i added logs in app.js, main.js etc but I dont see any logs in the developer console
  2. running the test within the launched window gives below image
  3. running npm test gives below

$ npm test

> yeoman-app@0.0.0 pretest D:\Projects\GIT\yeoman-app
> npm run lint

> yeoman-app@0.0.0 lint D:\Projects\GIT\yeoman-app
> eslint --ext=js --ext=jsx src spec

> yeoman-app@0.0.0 test D:\Projects\GIT\yeoman-app
> scripts/test.js

'scripts' is not recognized as an internal or external command,
operable program or batch file.
npm ERR! Test failed.  See above for more details.
  1. running npm run debug followed by npm run inspector gives below
$ npm run inspector

> yeoman-app@0.0.0 preinspector D:\Projects\GIT\yeoman-app
> open http://127.0.0.1:8080/?ws=127.0.0.1:8080&port=5858

'open' is not recognized as an internal or external command,
operable program or batch file.
'port' is not recognized as an internal or external command,
operable program or batch file.

npm ERR! Windows_NT 10.0.10586
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "inspector"
npm ERR! node v5.5.0
npm ERR! npm  v3.7.1
npm ERR! code ELIFECYCLE
npm ERR! yeoman-app@0.0.0 preinspector: `open http://127.0.0.1:8080/?ws=127.0.0.1:8080&port=5858`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the yeoman-app@0.0.0 preinspector script 'open http://127.0.0.1:8080/?ws=127.0.0.1:8080&port=5858'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the yeoman-app package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     open http://127.0.0.1:8080/?ws=127.0.0.1:8080&port=5858
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs yeoman-app
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls yeoman-app
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     D:\Projects\GIT\yeoman-app\npm-debug.log
stefanbuck commented 8 years ago

Note that logs defined in a file under src/browser/ are printed only to your terminal. Logs from src/render/ are visible only in the dev tool console.

deepu105 commented 8 years ago

There was no log on terminal as well On 3 Feb 2016 20:37, "Stefan Buck" notifications@github.com wrote:

Note that logs defined in a file under src/browser/ are printed only to your terminal. Logs from src/render/ are visible only in the dev tool console.

— Reply to this email directly or view it on GitHub https://github.com/yeoman/yeoman-app/issues/101#issuecomment-179200846.

stefanbuck commented 8 years ago

I'm downloading a window 10 VM right now ... stay tuned

stefanbuck commented 8 years ago

I've run into some issues with the windows 10 image. But good news, on windows 7 the app is working. Will continue tomorrow my windows session.

deepu105 commented 8 years ago

I can try on Linux but my goal is to get it working in Windows and provide any contribution possible from me

stefanbuck commented 8 years ago

Sure, we should definitely get it working on all common platforms. But I have no idea what cause the issue, right now. Thanks for your help :+1:

deepu105 commented 8 years ago

Im new to electron as well so trying to understand this, i don't see any logs in terminal, is there anything to be done to enable that? I tried putting logs everywhere but nothing shows up

Thanks & Regards, Deepu

On Thu, Feb 4, 2016 at 2:15 PM, Stefan Buck notifications@github.com wrote:

Sure, we should definitely get it working on all common platforms. But I have no idea what cause the issue, right now.

— Reply to this email directly or view it on GitHub https://github.com/yeoman/yeoman-app/issues/101#issuecomment-179665620.

deepu105 commented 8 years ago

Ok this is very weird, not sure if its an electron issue.

I always use git bash as my terminal in windows and was doing all this in it as well.

Just out of curiosity tried the same in a power-shell terminal and app works so not sure what is the problem.

If this wont be an issue when the actual packaged .exe is released then you can close this issue

stefanbuck commented 8 years ago

That's indeed strange. What about npm run build? Is it working and the build artifact executable?

deepu105 commented 8 years ago

no build still doesnt work

Thanks & Regards, Deepu

On Fri, Feb 5, 2016 at 3:44 AM, Stefan Buck notifications@github.com wrote:

That's indeed strange. What about npm run build? Is it working and the build artifact executable?

— Reply to this email directly or view it on GitHub https://github.com/yeoman/yeoman-app/issues/101#issuecomment-180019721.

deepu105 commented 8 years ago

here is trace from npm run build

PS D:\Projects\GIT\yeoman-app> npm run build

> yeoman-app@0.0.0 build D:\Projects\GIT\yeoman-app
> electron-compile --appDir . ./src/ ./static/ && node scripts/build.js

Path must be a string. Received undefined
Compilation failed!
For extra information, set the DEBUG environment variable to '*'

npm ERR! Windows_NT 10.0.10586
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\Deepu\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "run" "build"
npm ERR! node v5.5.0
npm ERR! npm  v3.7.1
npm ERR! code ELIFECYCLE
npm ERR! yeoman-app@0.0.0 build: `electron-compile --appDir . ./src/ ./static/ && node scripts/build.js`
npm ERR! Exit status 4294967295
npm ERR!
npm ERR! Failed at the yeoman-app@0.0.0 build script 'electron-compile --appDir . ./src/ ./static/ && node scripts/build.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the yeoman-app package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     electron-compile --appDir . ./src/ ./static/ && node scripts/build.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs yeoman-app
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls yeoman-app
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     D:\Projects\GIT\yeoman-app\npm-debug.log
PS D:\Projects\GIT\yeoman-app>

running electron-compile --appDir . ./src/ ./static/

electron-compile --appDir . ./src/ ./static/
Path must be a string. Received undefined
Compilation failed!
For extra information, set the DEBUG environment variable to '*'
PS D:\Projects\GIT\yeoman-app>

running node scripts/build.js

PS D:\Projects\GIT\yeoman-app> node scripts/build.js
[Error: Platform not supported yet!]
PS D:\Projects\GIT\yeoman-app>
stefanbuck commented 8 years ago

Opened a PR which should fix the build script https://github.com/yeoman/yeoman-app/pull/105

deepu105 commented 8 years ago

Damn this has stopped working again :( I dont know whats wrong now

deepu105 commented 8 years ago

doesnt work on latest master or my old branch which was working previously and my node env is still the same

stefanbuck commented 8 years ago

Let's try to clean up: remove the .cache folder and run npm prune.

deepu105 commented 8 years ago

ok

Thanks & Regards, Deepu

On Fri, Feb 19, 2016 at 2:39 PM, Stefan Buck notifications@github.com wrote:

Let's try to clean up: remove the .cache folder and run npm prune.

— Reply to this email directly or view it on GitHub https://github.com/yeoman/yeoman-app/issues/101#issuecomment-186087583.