Giter VIP home page Giter VIP logo

Comments (5)

kenany avatar kenany commented on August 14, 2024

I guess this is a nice-to-have kind of thing.

osi-licenses-full has the full license texts for several licenses. I guess this feature would go through each, calculate some "similarity" score with LICENSE and then just take a stab at defaulting on whatever license scored the highest?

from init-package-json.

brandonhorst avatar brandonhorst commented on August 14, 2024

licenses-utils does it by comparing files to static files stored as part of the module.
nlf does it by applying some regex.

Seems like either of these strategies would be fine.

from init-package-json.

brandonhorst avatar brandonhorst commented on August 14, 2024

The question I would have - where does this come into the hierarchy vs. config:init-license? Should the presence of a LICENSE always override the setting?

from init-package-json.

othiym23 avatar othiym23 commented on August 14, 2024

Should the presence of a LICENSE always override the setting?

That's the simplest and most intuitive thing to do. Explicit setting of the license in package.json trumps LICENSE, LICENSE trumps init.license, and init.license trumps the default (ISC).

from init-package-json.

dkundel avatar dkundel commented on August 14, 2024

I actually came here to create an issue for this. I tend to initialize a project with the respective LICENSE file on GitHub and run npm init -y afterwards. Would be great if it would detect the license automatically.

If this is something you would be up to have, I would be happy to look into creating a PR for this.

from init-package-json.

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.