List mesh peers

This commit is contained in:
Bob Mottram 2015-08-08 09:54:49 +01:00
parent a3503aec30
commit d99ea68211
1 changed files with 9 additions and 1 deletions

View File

@ -95,6 +95,11 @@ function mesh_babel {
echo '#!/bin/sh' > $babel_script
echo '' >> $babel_script
echo 'if [[ $1 == "ls" || $1 == "list" ]]; then' >> $babel_script
echo ' avahi-browse --all' >> $babel_script
echo ' exit 0' >> $babel_script
echo 'fi' >> $babel_script
echo '' >> $babel_script
echo 'if [[ $1 == "start" ]]; then' >> $babel_script
echo ' # install avahi' >> $babel_script
echo ' apt-get -y install avahi-utils avahi-autoipd' >> $babel_script
@ -277,9 +282,12 @@ function mesh_batman {
echo ' status)' >> $batman_script
echo ' batctl o' >> $batman_script
echo ' ;;' >> $batman_script
echo ' ls|list)' >> $batman_script
echo ' avahi-browse --all' >> $batman_script
echo ' ;;' >> $batman_script
echo ' *)' >> $batman_script
echo ' echo "error: invalid parameter $1"' >> $batman_script
echo ' echo "usage: $0 {start|stop|status}"' >> $batman_script
echo ' echo "usage: $0 {start|stop|status|ls|list}"' >> $batman_script
echo ' exit 2' >> $batman_script
echo ' ;;' >> $batman_script
echo 'esac' >> $batman_script