perforce / P4VS

[Officially Supported] VisualStudio plugin for HelixCore
Other
15 stars 6 forks source link

P4VS actions not working in CMake project #9

Open carterols opened 1 year ago

carterols commented 1 year ago

Hi,

None of the toolbar actions seem to work when opening a C/C++ CMake project. Note that I am using the Ninja generator instead of using the Visual Studio Generator. This means that no solution or .vsproj files are generated from the build. It is also worth noting that editing a file does successfully run a p4 edit, but any attempt to diff the file, revert it, submit it, etc. doesn't work.

Here are my important settings:

<DepotPathDlg.FilterCB.Checked type="bool">True</DepotPathDlg.FilterCB.Checked>
<P4V_path type="string">C:\Program Files\Perforce\p4v.exe</P4V_path>
<QueryEditAlwaysSync type="bool">False</QueryEditAlwaysSync>
<QueryEditNeverSync type="bool">True</QueryEditNeverSync>
<ConnectPreference type="int">0</ConnectPreference>
<Use_IP type="bool">False</Use_IP>
<Auto_logoff type="bool">False</Auto_logoff>
<Update_status type="int">5</Update_status>
<Number_files type="int">1000</Number_files>
<Size_files type="int">500</Size_files>
<Number_specs type="int">100</Number_specs>
<AutoUpdateFileData type="bool">False</AutoUpdateFileData>
<LazyLoadStatus type="bool">True</LazyLoadStatus>
<TreatProjectsAsFolders type="bool">True</TreatProjectsAsFolders>
<PreloadScmCache type="bool">False</PreloadScmCache>
<LazyLoadFullMenu type="bool">True</LazyLoadFullMenu>
<DisableParallelSync type="bool">False</DisableParallelSync>
<DisableParallelSubmit type="bool">False</DisableParallelSubmit>
<DisableParallelShelve type="bool">False</DisableParallelShelve>
<P4Diff_app type="bool">False</P4Diff_app>
<P4Diff_path type="string">C:\Program Files\Microsoft Visual Studio\2022\Preview\Common7\IDE\devenv.exe</P4Diff_path>
<P4Merge_app type="bool">True</P4Merge_app>
<P4Merge_path type="string">C:\Program Files\Perforce\P4Merge.exe</P4Merge_path>
<Launch_Swarm_Browser type="bool">False</Launch_Swarm_Browser>
<P4Date_format type="bool">True</P4Date_format>
<Revert_warn type="bool">True</Revert_warn>
<Checkout_lock type="bool">False</Checkout_lock>
<PromptForChanglist type="bool">False</PromptForChanglist>
<CheckoutWriteable type="bool">False</CheckoutWriteable>
<PromptForDelete type="bool">True</PromptForDelete>
<Auto_Add type="bool">True</Auto_Add>
<Update_Project type="bool">True</Update_Project>
<TagSolutionProjectFiles type="bool">False</TagSolutionProjectFiles>
<OpenShelvedFileInEditor type="bool">True</OpenShelvedFileInEditor>
<SetProjectFileLocation type="bool">True</SetProjectFileLocation>
<WarnSlnWorkspace type="bool">True</WarnSlnWorkspace>
<PromptSlnSync type="bool">True</PromptSlnSync>
<PromptOnNewIgnoreFile type="bool">True</PromptOnNewIgnoreFile>
<AddIgnoreFileToSolutuion type="bool">True</AddIgnoreFileToSolutuion>
<IgnoreIgnoredFiles type="bool">True</IgnoreIgnoredFiles>
<MarkIgnoreFileForAdd type="bool">False</MarkIgnoreFileForAdd>
<Log_command type="bool">True</Log_command>
<Log_reporting type="bool">True</Log_reporting>
<Log_save type="bool">False</Log_save>
<Log_size type="int">50</Log_size>

The output from attempting to first revert, then diff a file using the toolbar actions:

image

And the output of attempting to "diff against have revision": image

For more detail, the file I am attempting to perform these actions on is located at C:/workdir/msys64/home/carols9c/dev/main-cmake/src/common/test.cxx and the CMake workspace I have opened in Visual Studio is located at C:/workdir/msys64/home/carols9c/dev/main-cmake It seems as though the toolbar actions are not using the active file as the object to perform p4 actions on.