Giter VIP home page Giter VIP logo

npm's Introduction

WebJars

.github/workflows/test.yml

This is source for the http://www.webjars.org website. This is also the place to file requests for new WebJars.

For more information about WebJars visit the website: http://www.webjars.org

Development Info

Run the web app:

  1. Start a local memcache server
    docker run -p11211:11211 memcached
    
  2. ./sbt ~run

Note: Deploying WebJars to BinTray / Maven Central requires a bunch of stuff. In the future that will be documented but for now, deployment won't work in plain development environments.

Run the all tests:

  1. ./sbt test

Run a specific test, i.e.:

  1. testOnly utils.LicenseDetectorSpec -- ex "detect the license"
export OSS_GPG_PASS=asdf
export OSS_GPG_KEY=$(gpg --no-tty --pinentry-mode loopback --passphrase "$OSS_GPG_PASS" --export-secret-keys | base64 -w 0)

npm's People

Contributors

benmccann avatar huntc avatar jamesward avatar jroper avatar warry avatar wsargent avatar

Watchers

 avatar  avatar  avatar  avatar

npm's Issues

package.json misses version number

The webjar contains a generated package version that doesn't have a version number, but lib/npm.js tries to read the package.json at runtime to figure out the version number:

var j = parseJSON(fs.readFileSync(
  path.join(__dirname, '../package.json')) + '')
npm.name = j.name
npm.version = j.version

In effect, with the webjar, node .../path/to/contents/of/webjar/npm/bin/npm-cli.js --version prints undefined instead of the version of npm.

This appears to be a problem for us because the undefined is also triggered in some error messages that try to include the npm version number.

Maybe it would be better to include the upstream package.json from npm instead of generating a package.json just for the webjar, as happens currently:

<!-- webjars extractor needs a package.json to recognise this as a node module, 
     but npm no longer provides a package.json -->
<echo file="${destDir}/package.json" append="false">{
  "name": "npm"
}</echo>

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.