jspm / npm

NPM Location Service
19 stars 34 forks source link

Towards automated npm publishing workflows #110

Open guybedford opened 8 years ago

guybedford commented 8 years ago

Just to note the current plans here -

We want to eventually support jspm publish to publish the registry as listed in the package.json of the local project, with the name and version also taken from the package.json.

This would then run a publish hook of the registry implementation itself, which can do some sanitizing and init prompts as well.

There are two workflows we need to support for publishing to npm:

  1. Publishing within the standard Node & npm conventions. That means:
    • Check all dependencies from npm and named exactly as npm expects
    • Check any GitHub dependencies are in turn installed with the registry: 'npm' override
    • Confirm no use of plugin syntax
    • Build out plugins / formats to CJS to the dist folder
    • Generate modified package.json based on compatibility before publishing
    • Publishing files from the directories.dist folder only most likely will be the convention for all publish workflows.
  2. Publishing jspm conventions to npm. This means setting jspmPackage: true in the package.json before publishing.

The above would be very much like a wizard, with configuration options inferred as necessary. This is critical to being able to support proper ecosystems of code by encouraging and demonstrating the necessary conventions.

This is of course far-future stuff - jspm 0.18 at least.