coral-xyz / anchor

⚓ Solana Sealevel Framework
https://anchor-lang.com
Apache License 2.0
3.36k stars 1.25k forks source link

Fix npm warning by using configured default license #2929

Closed mikemaccana closed 2 months ago

mikemaccana commented 2 months ago

Currently when a new project is made with anchor init, running anchor test will display a warning because the package.json is missing the license field:

warning package.json: No license field

This PR uses the system's configured default license (ie, what npm init -y would use) to set the license for the new project.

People can set their system's default license with npm config set init-license "<license name>". Eg

Note this is my first PR to a Rust project, so if you have any suggestions for the code please let me know!

vercel[bot] commented 2 months ago

@mikemaccana is attempting to deploy a commit to the coral-xyz Team on Vercel.

A member of the Team first needs to authorize it.