Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added doc for Include ignored files #2146

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
12 changes: 10 additions & 2 deletions docs/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,15 +99,23 @@ npx babel src --out-file script-compiled.js

### Ignore files

Ignore spec and test files
Given files will be ignored from compilation and will not moved to destination.

```sh
npx babel src --out-dir lib --ignore "src/**/*.spec.js","src/**/*.test.js"
```

### Include ignored files

Copy the ignored files to destination.

```sh
npx babel src --out-dir lib --ignore --include-ignore "src/**/*.spec.js","src/**/*.test.js"
```

### Copy files

Copy files that will not be compiled
Copy incompatible files to the destination folder.

```sh
npx babel src --out-dir lib --copy-files
Expand Down
12 changes: 10 additions & 2 deletions website/versioned_docs/version-7.0.0/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -100,15 +100,23 @@ npx babel src --out-file script-compiled.js

### Ignore files

Ignore spec and test files
Given files will be ignored from compilation and will not moved to destination folder.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One tricky thing with this page, is that these are basically "recipes" for doing common things as opposed to a full detailed list of options.

Should we just keep the original text to match and maybe add a more noticeable section above this that links to options that replaces the easily missed "Advanced Usage" section at the bottom?


```sh
npx babel src --out-dir lib --ignore "src/**/*.spec.js","src/**/*.test.js"
```

### Include ignored files
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we need this addition to the versioned doc since --include-ignore is new?


Copy the ignored files to destination folder.

```sh
npx babel src --out-dir lib --ignore --include-ignore "src/**/*.spec.js","src/**/*.test.js"
```

### Copy files

Copy files that will not be compiled
Copy incompatible files to the destination folder.

```sh
npx babel src --out-dir lib --copy-files
Expand Down