Giter Site home page Giter Site logo

Comments (4)

fsquillace avatar fsquillace commented on July 24, 2024

Hi Gustavo,

I agree with you on this. Forcing the use to have the GNU coreutils might not be a good idea.

The only reason I forced it is because there are few packages that still requires GNU coreutils anyway. For instance kyrat is an example.

What I can do is following your approach. I can define a bash module like osx-compat.sh which will be sourced from all scripts that have GNU coreutils dependencies. This module will change PATH variable by prepending /usr/local/opt/coreutils/libexec/gnubin path. WDYT?

from pearl.

fsquillace avatar fsquillace commented on July 24, 2024

I am not a OSX expert, but I think in order to understand if the script is running on a OSX I could simply check that the path /usr/local/opt/coreutils/libexec/gnubin exists. Do you know an alternative way to do this?

from pearl.

guhcampos avatar guhcampos commented on July 24, 2024

I usually do a $(uname -s), this will return "Linux" on Linux boxes and "Darwin" for Mac OS X. I'm not sure for other flavors of BSD and POSIX though.

from pearl.

fsquillace avatar fsquillace commented on July 24, 2024

Change completed. Now, the user does not need to change the PATH variable anymore.
The installation process in OSX is greatly simplified: https://github.com/pearl-core/pearl#osx

However, Pearl packages that depends on GNU coreutils might be affected by this change although they will be easily fixed via the osx-compat.{fish,sh} files available: https://github.com/pearl-core/pearl/blob/master/lib/utils/osx-compat.sh

Thanks for catching this. It was a good one.

from pearl.

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.