Skip to content

Support: 'pub get' without dev_dependencies --only={prod[uction]|dev[elopment]} #2036

@jonasfj

Description

@jonasfj

When installing dependencies for use in production, you might wish to exclude dev_dependencies.

use-cases

  • Installing an application when building a docker image for use in the cloud.
  • Installing dependencies for analysis with pana
  • Installing an application in a production environment where dev_dependencies aren't needed

I'm sure there are more use-cases.

I suggest modeling this after npm which supports: npm install --only={prod[uction]|dev[elopment]}.

  • pub get --only=production only installs dependencies
  • pub get --only=development only installs dev_dependencies

We could also simply do pub get --production. But --only=... allows for more flexibility in the future.

Metadata

Metadata

Assignees

No one assigned

    Labels

    type-enhancementA request for a change that isn't a bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions