We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
git log -S ... -p ...
ublame is pretty close of what git log -S ... -p ... do : its diff is more concise and readable but it is way slower.
This refactoring consists in capturing git log -S ... -p ... output and stripping it to achieve current ublame output :
Algo would be :
❯ git log -G "ublame_cli" -p ublame/__init__.py commit 90e286119ac29090f54115bc5a908f1488d0d98b Author: Fabrice Laporte <fabrice@yescapa.com> Date: Sun Nov 15 10:25:49 2020 +0100 feat: accept multiple patterns as input ─────────────────────────────────────────────────────────────────────────────── modified: ublame/__init__.py ─────────────────────────────────────────────────────────────────────────────── @ ublame/__init__.py:41 @ def repo_path_for(filename): return filename def trim_diff(diff, token, context=3): def trim_diff(diff, patterns, context=3): """Keep only context surrounding searched token.""" if token in diff: [...] return any(diffs) or found @click.argument("patterns", nargs=-1, required=True) def ublame_cli(filename, patterns): filename = os.path.abspath(filename) repo_path = repo_path_for(filename) [...] ─────────────────────────────────────────────────────────────────────────────── added: ublame/__init__.py ─────────────────────────────────────────────────────────────────────────────── @ ublame/__init__.py:4 @ import blessed import os import click from pydriller import RepositoryMining, GitRepository ...
The text was updated successfully, but these errors were encountered:
No branches or pull requests
ublame is pretty close of what
git log -S ... -p ...
do : its diff is more concise and readable but it is way slower.This refactoring consists in capturing
git log -S ... -p ...
output and stripping it to achieve current ublame output :Algo would be :
The text was updated successfully, but these errors were encountered: