scripts: west_commands: completion: Add hwmv2 complete to zsh

Adds hwmv2 board completetion support to zsh

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
This commit is contained in:
Jamie McCrae
2024-02-22 13:57:12 +00:00
committed by Carles Cufi
parent b2af1e1737
commit 0f6842e2fa

View File

@@ -102,7 +102,11 @@ _get_west_projs() {
}
_get_west_boards() {
_west_boards=($(__west_x boards --format={name}))
_west_boards="$(__west_x boards --format={identifiers})\n$(__west_x boards --format={name})"
_west_boards=${_west_boards//$'\n'/\ }
_west_boards=${_west_boards//,/\ }
_west_boards=(${(@s/ /)_west_boards})
_describe 'boards' _west_boards
}