Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/editorconfig-checker/editorconfig-checker.python
A tool to verify that your files are in harmony with your .editorconfig
https://github.com/editorconfig-checker/editorconfig-checker.python
clean-code code-quality editorconfig editorconfig-checker lint linter linting
Last synced: 3 days ago
JSON representation
A tool to verify that your files are in harmony with your .editorconfig
- Host: GitHub
- URL: https://github.com/editorconfig-checker/editorconfig-checker.python
- Owner: editorconfig-checker
- License: other
- Created: 2019-08-28T11:07:46.000Z (about 5 years ago)
- Default Branch: main
- Last Pushed: 2024-09-06T22:26:18.000Z (2 months ago)
- Last Synced: 2024-09-26T08:09:12.323Z (about 1 month ago)
- Topics: clean-code, code-quality, editorconfig, editorconfig-checker, lint, linter, linting
- Language: Python
- Homepage:
- Size: 97.3 MB
- Stars: 38
- Watchers: 9
- Forks: 6
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# editorconfig-checker.python
A Python wrapper to provide a pip-installable [editorconfig-checker](https://github.com/editorconfig-checker/editorconfig-checker) binary.
Internally, this package provides a convenient way to download the pre-built `editorconfig-checker` binary for your particular platform.
## Installation
- From source code:
```
pip install .
```
- From `PyPI`:
```
pip install editorconfig-checker
```## Usage
After installation, the `ec` binary should be available in your environment (or `ec.exe` on Windows):
```
ec -version
```## Usage with the pre-commit git hooks framework
`editorconfig-checker` can be included as a hook for [pre-commit](https://pre-commit.com/).
The easiest way to get started is to add this configuration to your `.pre-commit-config.yaml`:```yaml
repos:
- repo: https://github.com/editorconfig-checker/editorconfig-checker.python
rev: '' # pick a git hash / tag to point to
hooks:
- id: editorconfig-checker
alias: ec
```The above hook is a python wrapper that automatically downloads and installs
[editorconfig-checker](https://editorconfig-checker.github.io/) binary.
If you manage your tools in some other way, for example, via [ASDF](https://asdf-vm.com/),
you may want to use an alternative pre-commit hook that assumes that
`ec` binary executable is already available on the system path:```yaml
repos:
- repo: https://github.com/editorconfig-checker/editorconfig-checker.python
rev: '' # pick a git hash / tag to point to
hooks:
- id: editorconfig-checker-system
alias: ec
```See the [pre-commit docs](https://pre-commit.com/#pre-commit-configyaml---hooks) to check how to customize this configuration.