Bruno Macabeus <bruno.macabeus@xxxxxxxxx> writes: > I should not create one commit just renaming the file and on another > commit updating its content, because the project won't build on the > first commit (since the build steps is different on a .ts file). And I > don't want to create a commit that the project can't be built on. Even if you did the two-step renaming, comparing the end result (i.e. HEAD) with the state before these two commits (i.e. HEAD~2, before renaming and before editing) with "git diff HEAD~2 HEAD" will not behave any differently if you did the renaming and modifying in a single commit. So it does not make much sense to split it into two artificial steps at all.