Go
Need help with node-prune?
Click the “chat” button below for chat support from the developer who created it, or find similar developers for support.
tj

Description

Remove unnecessary files from node_modules (.md, .ts, ...)

3.9K Stars 101 Forks MIT License 87 Commits 19 Opened issues

Services available

Need anything else?

What?

node-prune is a small tool to prune unnecessary files from ./node_modules, such as markdown, typescript source files, and so on. Primarily built for Up which lets you deploy serverless web applications in seconds.

Installation

From gobinaries.com:

$ curl -sf https://gobinaries.com/tj/node-prune | sh

From source:

$ go get github.com/tj/node-prune

Usage

In your app directory:

$ node-prune

files total 27,330 files removed 3,990 size removed 13 MB duration 200ms

Somewhere else:

$ node-prune path/to/node_modules

files total 27,330 files removed 3,990 size removed 13 MB duration 200ms

Or add to the

package.json
scripts field
  "scripts": {
    "postinstall": "node-prune"
  }

Why?

huge


GoDoc

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.