question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Could you please remove the dependency on `bash` to install this package

See original GitHub issue

I am submitting a…

  • Feature request
  • Design defect
  • Source code defect
  • Demo/documentation defect
  • Other

charts version:

All

Issue description

yarn install @carbon/charts on some windows will result in command not found as the post install has to run bash.

https://github.com/carbon-design-system/carbon-charts/blob/master/packages/core/package.json#L12

Steps to produce the issue

Try installing on a version of windows where WSL is not installed and bash is not installed.

Current behavior

It fails

Expected behavior

We should not be adding more friction to the install process by forcing a user to install extra tools just to satisfy some post install process.

If you require a post install script, then write it in JavaScript since, you absolutely know that it will be installed.

You should ban any script that is a .sh and simply use portable commands OR install dev dependencies such as shx that can be used to emulate most of the command commands that you’d run in a script.

In looking at the post install script this is simply doing a bunch of cp commands which means it all could have been put into the pacakge.json directly (yes, not as pretty, but would have workded at least).

As a project guideline you shoudl forbid any checkins of .sh files especially if htey are used as a post install.

Screenshot or recording

https://github.com/carbon-design-system/carbon-charts/blob/master/packages/core/package.json#L12

I’m a linux developer and I get that using bash can be handy… but unfortunately not everyone uses bash as their goto shell, especially on windows. The sad part for us, is that we are not using carbon charts, but depend on something else that just pulled it in between versions. So upgrading our dependency slipped us a cabon charts and then nuked many of our windows developers and qa people as they now had to decipher why they were getting a command not found error.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
stucklesscommented, Dec 2, 2019

Thx for the update… I’ll wait for newer library update (not from you) but from the dependency that I’m using, and hopefully that resolves my issues. But as of now, all windows developers has “bash” installed and as such it’s less of an issue. But, yeah, I guess bad timing 😦 thx again for the update.

0reactions
theiliadcommented, Dec 2, 2019

Btw the fix in v0.16.22 was pushed less than 24 hours after the bug was introduced.

It is really unlucky that the package you depend on pushed a new version within that timeframe using the broken 0.16.21 version.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to remove an uninstalled package's dependencies?
You can use the command apt-get autoremove . It will remove packages that are installed as automatic dependencies, but are not depended anymore....
Read more >
How to Remove Packages with Dependencies Using Yum
In this article, we will explain two ways to remove or uninstall a package along with their dependencies using YUM package manager in...
Read more >
Remove package and installed dependencies with apt-get
I understand what you're after, I'm just saying it can't be done currently. If apt-get remove --autoremove mypackage only removed autoremovable ...
Read more >
Uninstalling packages and dependencies
To remove a package from your node_modules directory, on the command line, use the uninstall command. Include the scope if the package is...
Read more >
How to Install and Correct Dependencies Issues in Ubuntu
Option 4: Clean the Package Dependencies ... A corrupted package database or packages that were broken or not installed properly can cause this ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found