Remove -l $logfile when listing avrdude commands

This commit is contained in:
stefanrueger
2024-02-05 15:13:43 +13:00
parent 7bf69aad43
commit cf2b362532

View File

@@ -164,7 +164,7 @@ emulated=0 # Is programmer dryrun or dryboot, ie, programmi
# Execute args as command, set $elapsed and return exit value of command; don't call in a subshell
execute () {
if [[ $list_only -eq 1 ]]; then
echo "\$ ${command[@]}" | tr -s " "
echo "\$ ${command[@]}" | sed "s/ -l [^ ]* / /" | tr -s " "
return 0;
fi
[[ $emulated -eq 0 && $elapsed != -1 ]] && sleep "$delay"
@@ -225,7 +225,7 @@ for (( p=0; p<$arraylength; p++ )); do
if [ "$key" == '' ]; then
FAIL=false
avrdude=($avrdude_bin $avrdude_conf -qq ${pgm_and_target[$p]} -l $logfile)
avrdude=($avrdude_bin -l $logfile $avrdude_conf -qq ${pgm_and_target[$p]})
# Get flash and EEPROM size in bytes and make sure the numbers are in dec form
FLASH_SIZE=$(${avrdude[@]} -cdryrun -T 'part -m' 2>/dev/null | grep flash | awk '{print $2}')