corriger affichage
This commit is contained in:
parent
1b7387ccf7
commit
b9fe0d47c3
4
SKvm
4
SKvm
|
@ -42,9 +42,9 @@ function build_arrays() {
|
||||||
# avms: toutes les vms
|
# avms: toutes les vms
|
||||||
# svms: les vms qui sont arrêtées
|
# svms: les vms qui sont arrêtées
|
||||||
rvms=()
|
rvms=()
|
||||||
eval "$(virsh_list | awk '{print $2}' | sort | sed 's/^/array_add rvms /g')"
|
eval "$(virsh_list | awk '{print $2}' | csort | sed 's/^/array_add rvms /g')"
|
||||||
avms=()
|
avms=()
|
||||||
eval "$(virsh_list --all | awk '{print $2}' | sort | sed 's/^/array_add avms /g')"
|
eval "$(virsh_list --all | awk '{print $2}' | csort | sed 's/^/array_add avms /g')"
|
||||||
svms=()
|
svms=()
|
||||||
for avm in "${avms[@]}"; do
|
for avm in "${avms[@]}"; do
|
||||||
array_contains rvms "$avm" || array_add svms "$avm"
|
array_contains rvms "$avm" || array_add svms "$avm"
|
||||||
|
|
|
@ -31,9 +31,9 @@ function build_arrays() {
|
||||||
# avms: toutes les vms
|
# avms: toutes les vms
|
||||||
# svms: les vms qui sont arrêtées
|
# svms: les vms qui sont arrêtées
|
||||||
rvms=()
|
rvms=()
|
||||||
eval "$(VBoxManage -q list runningvms | sort | sed 's/^/array_add rvms /g')"
|
eval "$(VBoxManage -q list runningvms | awk '{gsub(/[^"]*$/, ""); print}' | csort | sed 's/^/array_add rvms /g')" #"'bug colorisation
|
||||||
avms=()
|
avms=()
|
||||||
eval "$(VBoxManage -q list vms | sort | sed 's/^/array_add avms /g')"
|
eval "$(VBoxManage -q list vms | awk '{gsub(/[^"]*$/, ""); print}' | csort | sed 's/^/array_add avms /g')" #"'bug colorisation
|
||||||
svms=()
|
svms=()
|
||||||
for avm in "${avms[@]}"; do
|
for avm in "${avms[@]}"; do
|
||||||
array_contains rvms "$avm" || array_add svms "$avm"
|
array_contains rvms "$avm" || array_add svms "$avm"
|
||||||
|
|
Loading…
Reference in New Issue