mpyrpdiff
This tool generates a diff report (based on git diff) containing information about new, modified, and unchanged (original) files for two branches of a repository. The report is generated for the left branch (default: main) with respect to the right branch as a markdown file with the default name ‘FILES.md’.
Usage
mpyrpdiff --left-branch left-branch --right-branch right-branch [options]
Examples
Basic Branch Comparison
Compare a fork with its upstream:
mpyrpdiff --left-branch main --right-branch my-branch
Compare Two Repositories
It is possible to use the tool for comparing two repositories, e.g., a forked repository with respect to the original repository. For this, the main branch of the upstream repository has to be added to the current repository as a branch (recommended name: ‘upstream-main’).
This can be done with
git remote add upstream <url-of-upstream-repo>`
followed by
git fetch upstream && git checkout -b upstream-main upstream/main
After this, use --right-branch upstream-main to compare the two branches
mpyrpdiff --left-branch main --right-branch upstream-main --projectname MyFork
This will produce a FILES.md like the following
# Files in MyFork
## New Files
- src/new_solver/newSolver.C
- src/new_solver/newSolver.H
- applications/utilities/customTool/customTool.C
## Modified Files
- src/finiteVolume/interpolation/interpolation.C
- applications/solvers/multiphase/solver.C
## Copied Files
- src/mesh/meshTools/meshTools.C
- wmake/rules/General/general