renamed file are no more treated by sheldon
Description
When a file is renamed and modified, it should appear in sheldon and be treated.
This doesn't work presently.
Steps to reproduce
Rename a file.
Do a modification in the renamed file
Comit
Apply sheldon on the commit ( sheldon -f dev..HEAD)
The file is not checked by sheldon.
Proposal
The list of files is provided in common.py, l306 +308 in _diff. The -filter option has now A for "Added", M for "Modified". If R for "renamed" is added, all files are well detected, but the path retrieved is the original path and not the new one.
we need to change the regular expression in
files_in_rev()
to also read the new filename.
Functional specifications
Renamed files should be treated.
Only the destination path should be detected by sheldon, not the original one.
Technical specifications
- Add "R" in
--diff-filter=AMR
ingit show
parameters - Modify the regular expression to extract the renamed file name
Test plan
Edited by Michaël KUGLER