Coder Social home page Coder Social logo

Comments (6)

petetnt avatar petetnt commented on August 14, 2024

Most likely also resolved by #95

from js-buy-sdk.

yoadsn avatar yoadsn commented on August 14, 2024

I confirm the same when installing on a clean package.json (but nothing special in terms of high CPU - just the same error from postintall).
Windows 10 - using git bash.

I have merged locally build-on-pre-publish and got the same error now from the prepublish script:

> ./scripts/prepublish

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

So I assume #95 would not solve this for windows users if they are to publish the package. (I don't have a linux machine to test the publish now, I assume this is working fine).

The root issue here are the scripts in the "scripts" folder used by npm to build/publish etc. They rely on bash to run them, which (even if you run npm from git bash) is not available in windows CMD.. the default shell for npm run-script on windows.
Even if you do force the default shell to be the git bash, the call to npm run build from within the prepublish script itself runs in a windows CMD shell (which again, does not have bash).
This is a mix of weird compatibility issues that could be avoided using node scripts for the build process which are (mostly) xplat... take this into consideration if you want to make this build windows friendly..

from js-buy-sdk.

petetnt avatar petetnt commented on August 14, 2024

Regardless of the build scripts themselves, broccoli-lint-eslint needs to be updated to 2.2.1 too as 2.2.0 is broken on Windows too.

Even that isn't enough as after that broccoli fails on:

D:\foo\node_modules\shopify-buy>"node_modules/.bin/broccoli"  build dist
File: ajax.js
ReferenceError: [BABEL] ajax.js: Unknown option: D:\foo\.babelrc.presets
    at Logger.error (D:\foo\node_modules\shopify-buy\node_modules\broccoli-babel-transpiler\node_modules\babel-core\lib\transformation\file\logger.js:58:11)
    at OptionManager.mergeOptions (D:\foo\node_modules\shopify-buy\node_modules\broccoli-babel-transpiler\node_modules\babel-core\lib\transformation\file\options\option-manager.js:126:29)
    at OptionManager.addConfig (D:\foo\node_modules\shopify-buy\node_modules\broccoli-babel-transpiler\node_modules\babel-core\lib\transformation\file\options\option-manager.js:107:10)
    at OptionManager.findConfigs (D:\foo\node_modules\shopify-buy\node_modules\broccoli-babel-transpiler\node_modules\babel-core\lib\transformation\file\options\option-manager.js:168:35)
    at OptionManager.init (D:\foo\node_modules\shopify-buy\node_modules\broccoli-babel-transpiler\node_modules\babel-core\lib\transformation\file\options\option-manager.js:229:12)
    at File.initOptions (D:\foo\node_modules\shopify-buy\node_modules\broccoli-babel-transpiler\node_modules\babel-core\lib\transformation\file\index.js:147:75)
    at new File (D:\foo\node_modules\shopify-buy\node_modules\broccoli-babel-transpiler\node_modules\babel-core\lib\transformation\file\index.js:137:22)
    at Pipeline.transform (D:\foo\node_modules\shopify-buy\node_modules\broccoli-babel-transpiler\node_modules\babel-core\lib\transformation\pipeline.js:164:16)
    at Babel.transform (D:\foo\node_modules\shopify-buy\node_modules\broccoli-babel-transpiler\index.js:94:21)
    at Babel.processString (D:\foo\node_modules\shopify-buy\node_modules\broccoli-babel-transpiler\index.js:123:25)

Build failed

from js-buy-sdk.

minasmart avatar minasmart commented on August 14, 2024

Part of this is addressed by #102.

@petetnt: Can you point me at reference to [email protected] being broken on windows? I'll bump the version, I just want a bug that I can point to in the PR.

Thanks @petetnt and @yoadsn! All of your investigative work here is really appreciated.

from js-buy-sdk.

petetnt avatar petetnt commented on August 14, 2024

@minasmart This is the commit that fixes it: ember-cli/broccoli-lint-eslint@1b300cd and this is the issue ember-cli/broccoli-lint-eslint#35

Thanks @minasmart 👍

from js-buy-sdk.

minasmart avatar minasmart commented on August 14, 2024

Awesome! Thank you!

from js-buy-sdk.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.