We use a prebuilt version of VTK in our environment for Windows, but you can definitely run cmake.exe from a bat file. Smth like
cmake.exe" -G"Visual Studio 15 2017" -A x64 -DCMAKE_BUILD_TYPE=Release ^
-D ... ../
All variables are to be set with the -D option. You may want to follow the cmake docs that are quite profound.