Skip to content

Commit 5bf1f18

Browse files
committed
docs: remove mrm from README.md
1 parent c508b46 commit 5bf1f18

File tree

1 file changed

+15
-7
lines changed

1 file changed

+15
-7
lines changed

README.md

+15-7
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
Run linters against staged git files and don't let :poop: slip into your code base!
44

5+
```bash
6+
npm install --save-dev lint-staged # requires further setup
7+
```
8+
59
```
610
$ git commit
711
@@ -44,13 +48,17 @@ This project contains a script that will run arbitrary shell tasks with a list o
4448
4549
## Installation and setup
4650

47-
The fastest way to start using lint-staged is to run the following command in your terminal:
48-
49-
```bash
50-
npx mrm@2 lint-staged
51-
```
51+
To install _lint-staged_ in the recommended way, you need to:
5252

53-
This command will install and configure [husky](https://github.com/typicode/husky) and lint-staged depending on the code quality tools from your project's `package.json` dependencies, so please make sure you install (`npm install --save-dev`) and configure all code quality tools like [Prettier](https://prettier.io) and [ESLint](https://eslint.org) prior to that.
53+
1. Install _lint-staged_ itself:
54+
- `npm install --save-dev lint-staged`
55+
1. Set up the `pre-commit` git hook to run _lint-staged_
56+
- [Husky](https://github.com/typicode/husky) is a popular choice for configuring git hooks
57+
- Read more about git hooks [here](https://git-scm.com/book/en/v2/Customizing-Git-Git-Hooks)
58+
1. Install some linters, like [ESLint](https://eslint.org) or [Prettier](https://prettier.io)
59+
1. Configure _lint-staged_ to run linters and other tasks:
60+
- for example: `{ "*.js": "eslint" }` to run ESLint for all staged JS files
61+
- See [Configuration](#Configuration) for more info
5462

5563
Don't forget to commit changes to `package.json` and `.husky` to share this setup with your team!
5664

@@ -130,7 +138,7 @@ Options:
130138

131139
## Configuration
132140

133-
Starting with v3.1 you can now use different ways of configuring lint-staged:
141+
_Lint-staged_ can be configured in many ways:
134142

135143
- `lint-staged` object in your `package.json`
136144
- `.lintstagedrc` file in JSON or YML format, or you can be explicit with the file extension:

0 commit comments

Comments
 (0)