3.2.0 • Published 2 years ago

@s-ui/precommit v3.2.0

Weekly downloads
1,089
License
MIT
Repository
github
Last release
2 years ago

sui-precommit

Effortless SUI precommit rules integration in your project

Installs git hooks to ensure quality rules are executed before any commit (test, linting, consistent commit, etc).

It provides:

  • Assurance that all code is compliant with Adevinta's standards.
  • Centralize precommit rule: quality rules can be improved and seemlessly inherited by all projects.

Installation

$ npm install @s-ui/precommit --save-dev

CLI

$ sui-precommit

Installs git hooks. This command is executed automatically when you install @s-ui/precommit as dependency thanks to a postinstall npm hook.

Executes 3 actions:

  1. Add commit-msg, pre-commit, and pre-push hooks to the .git/hooks folder.
  2. Add pre-commit and pre-push npm scripts to the package.json.
  3. Add lint and test npm scripts in case they're not present. Note: If scripts are already present, it doesn't overwrite them (as some packages might not need executing sui-lint sass or sui-lint js or you could have a specific config).

Your package.json might be altered like that:

{
  "scripts": {
    "lint": "sui-lint js && sui-lint sass",
    "test": "echo \"Error: no test specified\" && exit 1",
    "pre-commit": "npm run lint",
    "pre-push": "npm run test"
  }
}
3.2.0

2 years ago

2.16.0-beta.7

2 years ago

2.16.0-beta.6

2 years ago

2.16.0-beta.5

2 years ago

2.16.0-beta.4

2 years ago

3.1.0

2 years ago

2.16.0-beta.3

2 years ago

2.16.0-beta.2

2 years ago

3.0.0

2 years ago

2.15.0

2 years ago

2.15.0-beta.3

3 years ago

2.16.0-beta.1

3 years ago

2.16.0-beta.0

3 years ago

2.15.0-beta.0

3 years ago

2.15.0-beta.2

3 years ago

2.15.0-beta.1

3 years ago

2.14.0

3 years ago

2.13.0

3 years ago

2.12.0

3 years ago

2.11.0

4 years ago

2.10.0

4 years ago

2.9.0

4 years ago

2.8.0-beta.8

4 years ago

2.8.0

4 years ago

2.8.0-beta.5

4 years ago

2.8.0-beta.7

4 years ago

2.8.0-beta.4

4 years ago

2.8.0-beta.3

4 years ago

2.8.0-beta.2

4 years ago

2.8.0-beta.1

4 years ago

2.8.0-beta.0

4 years ago

2.7.0

5 years ago

2.6.0

5 years ago

2.5.0

6 years ago

2.4.0

7 years ago