"C:\Users\Huxley\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\ESP-IDF"
(The desktop probably is a better place for the ESP-IDF shortcut, since the Start Menu is hidden on Windows after version 7, and most people do not know how to find it.)
Inside the command window, I found the following messages:
Code: Select all
Using Python in C:\Program Files\Python37\
Python 3.7.4
Using Git in C:\Program Files\Git\cmd
git version 2.21.0.windows.1
Setting IDF_PATH: c:\Users\Huxley\esp\esp-idf
Adding ESP-IDF tools to PATH...
Not using an unsupported version of tool cmake found in PATH: 3.15.4.
The input line is too long.
The syntax of the command is incorrect.
c:\users\Huxley\esp\esp-idf>
I commented out the "@ECHO OFF" statement at the top of ".espressif/idf_cmd_init.bat" and "esp-idf/export.bat", and I ran the ESP-IDF shortcut to find the cause of "The input line is too long." error message.
The error occurs in "esp-idf/export.bat" while it's manipulating the environment "path" variable. Where the error occurs, the string that represents the path variable has grown to more than 4400 characters. When I report the path variable from the ESP-IDF window, I see a couple of problems. The first part of the path variable is:
PATH=C:\Users\Huxley\.espressif\tools\esp32ulp-elf\2.28.51.20170517\esp32ulp-elf-binutils\bin;
C:\Users\Huxley\.espressif\tools\cmake\3.13.4\bin;
C:\Users\Huxley\.espressif\tools\openocd-esp32\v0.10.0-esp32-20190708\openocd-esp32\bin;
C:\Users\Huxley\.espressif\tools\idf-exe\1.0.1\;
C:\Users\Huxley\.espressif\tools\ccache\3.7\;
C:\Users\Huxley\.espressif\python_env\idf4.1_py3.7_env\Scripts;
c:\Users\Huxley\esp\esp-idf\tools;
C:\Program Files\Python37\;
C:\Program Files\Git\cmd;
PATH=C:\Program Files\Python27\;
C:\Program Files\Python27\Scripts;
C:\Program Files\Python37\Scripts\;
C:\Program Files\Python37\;
You can see that "PATH=" appears more than once in the path definition, which is unusual.
Elsewhere in the path, a large section of the path appears to be repeated, also indicating that something has gone wrong inside either .espressif/idf_cmd_init.bat or esp-idf/export.bat. The total length of the path after .espressif/idf_cmd_init.bat has completed is over 3000 characters. Without the repetition, it might be closer to 2000 characters.
I'm not a Windoows batch file expert, but the problem in esp-idf/export.bat may be an artifact of the fact that in an ordinary Windows command window, my path variable is just over 1600 characters.
As far as I know, the Windows path is limited to 4095 characters, while the maximum command line length is 8191 characters. That doesn't quite jibe with the error messages appearing in the ESP-IDF command window, but the limits within the batch processor may not be the same as they are at the command prompt.