Skip to content

Commit

Permalink
Update nodejs-apps.bash (#1819)
Browse files Browse the repository at this point in the history
provide a workaround for the debian bug with missing /dev/serial/by-id. In this case /dev/serial/by-path is scanned

Signed-off-by: Carsten Mogge <carsten.mogge@gmail.com>
  • Loading branch information
Larsen-Locke authored Oct 8, 2023
1 parent 0b81e6d commit dc8e23d
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions functions/nodejs-apps.bash
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,14 @@ zigbee2mqtt_setup() {
my_adapters="$my_adapters $line $loopSel "
loopSel=0
done < <( ls /dev/serial/by-id )

if [[ $my_adapters == "" ]] ; then
while IFS= read -r line; do
my_adapters="$my_adapters $line $loopSel "
loopSel=0
done < <( ls /dev/serial/by-path )
fi

unset IFS

# ask for user input parameters
Expand Down

0 comments on commit dc8e23d

Please sign in to comment.