Jump to content

cm diff that includes files from inside directories


po100lak

Recommended Posts

Hello,

I have a branch. In one of the changesets I renamed a directory. Inside that directory there were files. Now I want to create a full diff of said branch, but I cannot make it so that it includes the files inside the changed directories.

obraz.png.5620844402a386fc63371d8acf022f71.png

cm diff br:$BRANCH_FULL_NAME --repositorypaths --moved --format="M {srccmpath} revid: {revid} parentrevid: {parentrevid} baserevid: {baserevid}"
M "/resources/tests/jednostkowe/Doubles/Globals/Model" revid: 2008419 parentrevid: 2001744 baserevid: -1
M "/resources/tests/jednostkowe/lib/ObiRepoTable.php" revid: 2008385 parentrevid: 1628720 baserevid: -1

It is crucial to have a full list of for the sake of code review generation, as it have to match everything generated in a patch file, and the patch file includes the files from inside the directory that had its name changed, as shown in the picture below. As you can see, the highlighted path of a file is the first file from the directory seen in the picture above.

cm patch br:$BRANCH_FULL_NAME > patch.diff

obraz.thumb.png.bef0b9d88c5e6a5b3588db06a6a44bf2.png

 

 

Link to comment
Share on other sites

Hi,

But note that in this scenario what you are chaning is the folder name (not the files inside the folder). That's why the files doesn't appear in the diff view (because they were not changed).

For instance, if you rename a folder that has 100k files inside, the diff view would be polluted by thousands of items that were not actually changed.

Also if you are renaming a root folder, you are not renaming all the subfolders inside. The diff view only shows the specific items (folders/files) you are actually changing.

If you want to list the items of a folder, you can use the "cm ls" commands.

PD: There is a "cm diff cs:<id> --download=C:\MyPath" but I think it doesn't help for your needs.

Regards,

Carlos.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...