Skip to content

Commit

Permalink
chore: add missing READMES to packages (#545)
Browse files Browse the repository at this point in the history
  • Loading branch information
evenstensberg authored Jul 18, 2018
1 parent d6a433b commit a2f10e9
Show file tree
Hide file tree
Showing 12 changed files with 283 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/add/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Description

This package contains the logic to add new properties to the a webpack configuration file. It will run a generator that prompts the user for questions of which property to add to their webpack configuration file.
This package contains the logic to add new properties in a webpack configuration file. It will run a generator that prompts the user for questions of which property to add to their webpack configuration file.

## Installation

Expand Down
27 changes: 27 additions & 0 deletions packages/generate-loader/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# webpack-cli generate-loader

## Description

This package contains the logic to initiate new loader projects.

## Installation

```bash
npm i -D webpack-cli @webpack-cli/generate-loader
```

## Usage

To run the package programmatically, install it as a dependency. When using the package programmatically, one does not have to install webpack-cli.

### Node

```js
const generateLoader = require("@webpack-cli/generate-loader");
generateLoader();
```

### CLI (via `webpack-cli`)
```bash
npx webpack-cli generate-loader
```
26 changes: 26 additions & 0 deletions packages/generate-plugin/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# webpack-cli generate-plugin

## Description

This package contains the logic to initiate new plugin projects.

## Installation

```bash
npm i -D webpack-cli @webpack-cli/generate-plugin
```

## Usage

To run the package programmatically, install it as a dependency. When using the package programmatically, one does not have to install webpack-cli.

### Node
```js
const generatePlugin = require("@webpack-cli/generate-plugin");
generatePlugin();
```

### CLI (via `webpack-cli`)
```bash
npx webpack-cli generate-plugin
```
34 changes: 34 additions & 0 deletions packages/generators/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# webpack-cli generators

## Description

This package contains all webpack-cli related yeoman generators.

## Installation

```bash
npm i -D webpack-cli @webpack-cli/generators
```

## Usage

To run the package programmatically, install it as a dependency. When using the package programmatically, one does not have to install webpack-cli.

## Generators

- Plugin Generator
- Remove Generator
- Update Generator
- Loader Generator
- Init Generator
- Add Generator


### Node

```js
const { addGenerator, addonGenerator, initGenerator, loaderGenerator,
pluginGenerator, removeGenerator, updateGenerator
} = require("@webpack-cli/generators");
// ... compose with yeoman env or add a generator to your own yeoman project
```
3 changes: 2 additions & 1 deletion packages/info/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Description

It returns a set of information related to the local enviroment.
This pacakge returns a set of information related to the local enviroment.

## Installation

Expand All @@ -13,6 +13,7 @@ npm i -D @webpack-cli/info
## Usage

### Node

```js
const envinfo = require("@webpack-cli/info");
envinfo();
Expand Down
32 changes: 32 additions & 0 deletions packages/init/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# webpack-cli init

## Description

This package contains the logic to create a new webpack configuration.

## Installation

```bash
npm i -D webpack-cli @webpack-cli/init
```

## Usage

To run the package programmatically, install it as a dependency. When using the package programmatically, one does not have to install webpack-cli.

### Node

```js
const init = require("@webpack-cli/init");

// this will run the default init instance
init();

// we're slicing node.process, ...myPacakges is a webpack-scaffold name/path
init([null, null, ...myPacakges]);
```

### CLI (via `webpack-cli`)
```bash
npx webpack-cli init
```
26 changes: 26 additions & 0 deletions packages/make/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# webpack-cli make (Work in Progress, not yet published)

## Description

This package contains the logic to run a makefile command similar to C in webpack.

## Installation

```bash
npm i -D webpack-cli @webpack-cli/make
```

## Usage

To run the package programmatically, install it as a dependency. When using the package programmatically, one does not have to install webpack-cli.

### Node
```js
const make = require("@webpack-cli/make");
make();
```

### CLI (via `webpack-cli`)
```bash
npx webpack-cli make
```
28 changes: 28 additions & 0 deletions packages/migrate/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# webpack-cli migrate

## Description

This package contains the logic to migrate a project from one version to the other.

## Installation

```bash
npm i -D webpack-cli @webpack-cli/migrate
```

## Usage

To run the package programmatically, install it as a dependency. When using the package programmatically, one does not have to install webpack-cli.

### Node
```js
const migrate = require("@webpack-cli/migrate");

// add null to mock process.env
migrate(null, null, inputPath, outputPath);
```

### CLI (via `webpack-cli`)
```bash
npx webpack-cli migrate
```
26 changes: 26 additions & 0 deletions packages/remove/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# webpack-cli remove

## Description

This package contains the logic to remove properties of a webpack configuration file. It will run a generator that prompts the user for questions of which property to remove in their webpack configuration file.

## Installation

```bash
npm i -D webpack-cli @webpack-cli/remove
```

## Usage

To run the scaffolding instance programmatically, install it as a dependency. When using the package programmatically, one does not have to install webpack-cli.

### Node
```js
const remove = require("@webpack-cli/remove");
remove();
```

### CLI (via `webpack-cli`)
```bash
npx webpack-cli remove
```
26 changes: 26 additions & 0 deletions packages/serve/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# webpack-cli serve

## Description

This package contains the logic to run webpack-serve without using webpack-serve directly.

## Installation

```bash
npm i -D webpack-cli @webpack-cli/serve
```

## Usage

To run the scaffolding instance programmatically, install it as a dependency. When using the package programmatically, one does not have to install webpack-cli.

### Node
```js
const serve = require("@webpack-cli/serve");
serve();
```

### CLI (via `webpack-cli`)
```bash
npx webpack-cli serve
```
26 changes: 26 additions & 0 deletions packages/update/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# webpack-cli update

## Description

This package contains the logic to update properties in a webpack configuration file. It will run a generator that prompts the user for questions of which property to update in their webpack configuration file.

## Installation

```bash
npm i -D webpack-cli @webpack-cli/update
```

## Usage

To run the scaffolding instance programmatically, install it as a dependency. When using the package programmatically, one does not have to install webpack-cli.

### Node
```js
const update = require("@webpack-cli/update");
update();
```

### CLI (via `webpack-cli`)
```bash
npx webpack-cli update
```
29 changes: 29 additions & 0 deletions packages/utils/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# webpack-cli utils (WIP, not yet published)

## Description

This package contains the utilities used across the webpack-cli repositories.

## Installation

```bash
npm i -D webpack-cli @webpack-cli/utils
```

## Contents
- AST transformations
- Checking NPM registry
- A Recursive AST parser
- Checking Local Configurations
- Yeoman Generator Adapter
- Package Resolver
- Test Utilities for Jest

## Usage

### Node

```js
const utils = require("@webpack-cli/utils");
// API yet to be exposed
```

0 comments on commit a2f10e9

Please sign in to comment.