runisland / meteor-ionic4

Meteor Atmosphere package that automatically imports Ionic4 Web Components into your Client templates
MIT License
14 stars 6 forks source link

Build script running under Windows #2

Closed atao60 closed 6 years ago

atao60 commented 6 years ago

Add ability to build the package on a workstation under Windows: replace Linux commands by node commands in npm scripts.

ghybs commented 6 years ago

Hi,

Thank you for the 2 PR's! Sorry for the delay before reviewing them, I had to get a Windows machine...

Thank you for having ported the scripts for compatibility with Windows!

However when executing npm run clean, the script correctly removes the node_modules folder, but generates an error:

> runisland-ionic4@4.0.0-alpha.7 clean [path\to]\meteor-ionic4 > rimraf ./node_modules

[cannot find the path specified] npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! runisland-ionic4@4.0.0-alpha.7 clean: `rimraf ./node_modules` npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the runisland-ionic4@4.0.0-alpha.7 clean script.

I guess it is because it removes the rimraf bin that was contained in the node_modules folder? Having rimraf package globally installed in parallel does not change the situation (I guess even though it is globally available, npm tries to use the local version first).

Do you also have that error? If so, how would you modify the script to get rid of it?

Of course the current result is still acceptable (i.e. the node_modules folder and the package state is correct), but I would prefer avoiding keeping a false error that could hide a true issue in the future.

atao60 commented 6 years ago

I guess it is because it removes the rimraf bin that was contained in the node_modules folder?

yes

Do you also have that error?

yes

If so, how would you modify the script to get rid of it?

I haven't any idea about how to do it. I'd have to dig a little.

but I would prefer avoiding keeping a false error that could hide a true issue in the future.

Sure

atao60 commented 6 years ago

Can you check if my last commit is working on your Windows machine?

I kept rimraf for ./dist but replaced it by a node script for ./node_modules

ghybs commented 6 years ago

Hi,

Yes it works fine on my Windows and Linux, so merging! Thank you for your contribution! :+1: :smiley: