4 afb-client-demo -H -d unix:@afm_platform_rundir@/apis/ws/afm-main "$1" "$2" |
5 awk '$1=="ON-REPLY" && $3!="success"{$1="ERROR:";$2="";print > "/dev/stderr";exit 1;}NR>1'
10 -a|--all) echo -n '{"all":true}';;
18 send runnables $(getall $2)
24 if [[ "$(basename $0)" = "afm-install" ]]; then r=false; fi
25 send install '{"wgt":"'"$f"'","force":true,"reload":'"$r"'}'
30 send uninstall "\"$i\""
39 send runners $(getall $2)
47 run-remote|start-remote)
49 send start '{"id":"'"$i"'","mode":"remote"}'
79 usage: $(basename $0) command [arg]
84 runnables list the runnable widgets installed
85 option -a or --all for all instances
88 install wgt install the wgt file
91 uninstall id remove the installed widget of id
94 detail id print detail about the installed widget of id
97 runners list the running instance
98 option -a or --all for all instances
101 start id start an instance of the widget of id
103 once id run once an instance of the widget of id
106 terminate rid terminate the running instance rid
109 pause rid pause the running instance rid
112 continue rid continue the previously paused rid
115 state rid get status of the running instance rid
121 echo "unknown command $1" >&2