Wednesday, October 18, 2023

Solution: TortoiseSVN Background contextmenu not visible after publishing

After publishing the App-V sequenced TortoiseSVN, all the context menu shortcuts are visible and it works fine. Only the background context menu option is not visible. In this blog, I will demonstrate and provide a solution for it.


First download the TortoiseSVN software from the below link.
https://tortoisesvn.net/downloads.html


Download the Latest windows ADK so that we can use the latest App-V Sequencer from the below link.
https://docs.microsoft.com/en-us/windows-hardware/get-started/adk-install


Sequence the TortoiseSVN application using default steps.


Even if you use PVAD when sequencing, we can see the same issue that the background context menu is not visible after publishing.
After Publishing the sequenced package, we can see that when we right click file\folder\drive the context menu option is visible as App-V will install those respective registry entries in the local machine and they will be used by the explorer due to dynamic virtualization concept.


FILE:





FOLDER:



But when we right click on empty explorer window or inside any folder empty place, the below options are not visible as seen in the native installed package.






We can see that in the sequencer machine, the following registry responsible for the background context menu is registered in the local machine.









Even in the package editor we can see that those registry keys are captured.





Even in the AppxManifest file we can see those shell entries.







But after publishing and seeing the local HKCR registry, the particular key alone is missing. All other context menu registries are visible.










Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\Directory\Background\shellex\ContextMenuHandlers\TortoiseSVN]
@="{30351349-7B7D-4FCC-81B4-1E394CA267EB}"


To Fix the issue, copy the above registry key and install in native machine.To Add it with the sequenced package, first export the AppxManifest.xml file and edit it using AVME from the below link.


Edit the XML file and add like below in AddPackage and Remove Package tabs.



Once done save the AppxManifest.xml file and import it back to the package using sequencer.




Save the package and publish it to the client machine. Now you can see the context menu when you click on empty explorer window or empty space inside directory.
You can also add the registry using scripts in deploymentconfig/userconfig file too.

As pointed by Roy Essers in a TechNet post, this indeed seems to be App-V sequencer bug and MS needs to fix this soon.