MBulli / SmartCommandlineArgs

A Visual Studio Extension which aims to provide a better UI to manage your command line arguments
GNU General Public License v2.0
99 stars 35 forks source link

SmartCmdArgJsonFile is not read #89

Closed ror3d closed 5 years ago

ror3d commented 5 years ago

I'm using CMake 3.13 and Visual Studio 2017.

I set up the project property as indicated in the cmake help page:

if ("${CMAKE_GENERATOR}" MATCHES "Visual Studio*")
    get_filename_component(smartCmdArgJsonFile "SmartCmd.args.json" ABSOLUTE)
    set_property(TARGET ${PROJECT_NAME} PROPERTY VS_GLOBAL_SmartCmdArgJsonFile ${smartCmdArgJsonFile})
endif()

And I have checked in the .vcproj file that it has the proper value. If I change the configurations in the command arguments window, the file is created/modified in the configured location.

The problem appears when the project is loaded: it seems to try to load the file from the default location instead of the file in the SmartCmdArgJsonFile variable. If I just open the project, no command line arguments are present. If I copy the .json file to the .vcproj directory with the same name as the .vcproj, then when loading the project it does load that configuration from there. After that, it stores the configuration in the file indicated by SmartCmdArgJsonFile.

MBulli commented 5 years ago

For me the command list is empty when I change the CMakeLists.txt while VS is open. After compiling my project VS asks me to reload the solution and after the reload the command list is empty.

We'll check that!