Skip to content

[ci] ignore ruff-format changes in git blame (fixes #6304) - #6345

Merged
jameslamb merged 2 commits into
masterfrom
git-blame-ignore
Feb 29, 2024
Merged

jameslamb merged 2 commits into
masterfrom
git-blame-ignore

Conversation

@jameslamb

@jameslamb jameslamb commented Feb 28, 2024 •

Copy link
Copy Markdown
Member

Fixes #6304.

Adds the recent ruff-format commits to a .git-blame-ignore-revs file, so those changes that touched a LOT of lines are ignored in the git blame.

For details on that, see https://docs.github.com/en/repositories/working-with-files/using-files/viewing-a-file#ignore-commits-in-the-blame-view

How I tested this

Look at the blame view on this branch: https://github.com/microsoft/LightGBM/blame/git-blame-ignore/python-package/lightgbm/basic.py.

Screen Shot 2024-02-27 at 10 03 17 PM

Scrolled through there and did not see any of the formatting changes in the blame.

@borchero borchero left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't know this feature yet, very useful! 😱

@jameslamb
jameslamb merged commit 1a292f8 into master Feb 29, 2024
@jameslamb
jameslamb deleted the git-blame-ignore branch February 29, 2024 05:30
@github-actions

github-actions Bot commented Mar 6, 2025

Copy link
Copy Markdown
Contributor

This pull request has been automatically locked since there has not been any recent activity since it was closed.
To start a new related discussion, open a new issue at https://github.com/microsoft/LightGBM/issues including a reference to this.

@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Mar 6, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[RFC] [python-package] use black for formatting Python code?

3 participants