No project description provided
Project description
match-diff-lines
Match a diff to a list of lines from linters and other tools like flake8 or ruff.
Installation
Best to install into a virtual environment with a Python installer like pip or similar.
Usage
Invoke python -m match_diff_lines diff_file tool_output. The diff_file is a file containing the unified diff output you want to check against. The tool_output contains the output of your linter/tool which contains lines in the form of filename:line_num for example:
match_diff_lines.py:59:39: E271 multiple spaces after keyword
If any lines are contained in the diff, then they are printed and exit code 1 is returned.
With bash or zsh you can use temporary named pipes like this:
% python -m match_diff_lines <(git diff HEAD^) <(ruff check)
Changelog
0.1.0 - Unreleased
Initial release. [fschulze]
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file match_diff_lines-0.1.0.tar.gz
.
File metadata
- Download URL: match_diff_lines-0.1.0.tar.gz
- Upload date:
- Size: 3.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: devpi-server/6.6.0 (py3.8.6; darwin)
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0fe6f63d3ed48269e38f98ce5d1b847296bd0f7bb75e1131cec3b5dfeeee2f73 |
|
MD5 | f437805dd228522c09c1dcdd65aaf701 |
|
BLAKE2b-256 | 3aae57e73891e3b894a79abee06621a3d4232fd3e1b5d6c04777a75c6aa8ab56 |
File details
Details for the file match_diff_lines-0.1.0-py3-none-any.whl
.
File metadata
- Download URL: match_diff_lines-0.1.0-py3-none-any.whl
- Upload date:
- Size: 4.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: devpi-server/6.6.0 (py3.8.6; darwin)
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8667e34495b2ed4fa00dace5985e7449fd1ba00f471a2a02a3fb21a4477c657f |
|
MD5 | 3f8679d6488c1bd0062d94c1035cc291 |
|
BLAKE2b-256 | fb1ee5006f01d7f00079b2a064fadf58a5be5d39735b510f44f9fbeebfdd9527 |