User tests: Successful: Unsuccessful:
Git offers the possibility to exclude code style commits in git blame https://git-scm.com/docs/git-blame#Documentation/git-blame.txt---ignore-revs-fileltfilegt. Github is supporting this feature as well https://docs.github.com/en/repositories/working-with-files/using-files/viewing-a-file#ignore-commits-in-the-blame-view.
This pr adds the PSR 12 conversion and some other CS commits to the file .git-blame-ignore-revs, which should be excluded in blame then.
Want to test this, browse around in https://github.com/Digital-Peak/joomla-cms/tree/blame and open the blame view. The commits should not be displayed there.
Status | New | ⇒ | Pending |
Labels |
Added:
PR-4.3-dev
|
Not sure why this one is not excluded, the other ones are. For example #39616 is excluded as you can see here https://github.com/Digital-Peak/joomla-cms/blame/blame/libraries/cms.php when you compare it with https://github.com/Digital-Peak/joomla-cms/blame/4.4-dev/libraries/cms.php.
I also don't see the failed warning, the correct one is displayed:
When I do it on command line, then it works also with the PSR 12 one.
Maybe GitHub has a bug when using the "blame" function on a branch with name "blame"?
Maybe, as the commit hash should be the correct one.
thanks I have one similar to this but only local
Status | Pending | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2023-05-24 16:16:15 |
Closed_By | ⇒ | obuisard |
I had another look @richard67 and the PSR 12 entry with the blank line on line 2 is because this line was added through that commit and there is no previous commit. So git has to show that commit as it is the first one. But when you compare the file libraries/cms.php on the 4.3 branch with the on from 5.0, which doesn't have the ignore pr merged up, then the other PSR 12 changes are not listed, because there are some older commits on these lines, check line 13 on the next two screenshots.
@laoneo Doesn't work here: