Switch back to old version
This commit is contained in:
@ -5,6 +5,9 @@ import subprocess
|
||||
# execute './switchconf.sh --list' to get the list of available configurations
|
||||
output = subprocess.check_output(['bash', './switchconf.sh', '--list']).decode('utf-8').splitlines()
|
||||
|
||||
# read symlink './sdkconfig' to get the current configuration
|
||||
current_config = os.readlink('./sdkconfig')
|
||||
|
||||
if len(output) == 0:
|
||||
print('No configurations found!')
|
||||
exit(1)
|
||||
@ -18,4 +21,8 @@ for config in output:
|
||||
print('Switching to configuration: ' + config)
|
||||
subprocess.check_call(['bash', './switchconf.sh', config])
|
||||
# execute idf.py menuconfig and wait for user to close again
|
||||
subprocess.check_call(['idf.py', 'menuconfig'])
|
||||
subprocess.check_call(['idf.py', 'menuconfig'])
|
||||
|
||||
# switch back to current configuration
|
||||
print('Switching back to configuration: ' + current_config)
|
||||
subprocess.check_call(['bash', './switchconf.sh', current_config])
|
Reference in New Issue
Block a user