It would be nice if HADOOP_CONF_DIR could be set in the environment like YARN_CONF_DIR. This could be done in lib-exec/hadoop.cmd by setting HADOOP_CONF_DIR conditionally.
Using the Windows command shell, the modification would be as follows:
if not defined HADOOP_CONF_DIR (
This would allow the Hadoop configuration to be placed in ProgramData more easily.