From: Simon Wunderlich <sw@simonwunderlich.de>
To: b.a.t.m.a.n@lists.open-mesh.org
Subject: Re: [B.A.T.M.A.N.] Suggestions to get extended jsondoc alfred output
Date: Mon, 28 Sep 2015 19:35:25 +0200 [thread overview]
Message-ID: <1942201.vOz91KHqBg@prime> (raw)
In-Reply-To: <5609712B.6020308@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1705 bytes --]
On Monday 28 September 2015 18:56:11 Germano Massullo wrote:
> I created three Fedora virtual machines to get some alfred jsondoc
> format output. I followed [1] and [2] but I edited some commands because
> virtual machines obviously do not own wireless network interfaces. Since
> it is the first time I use batman+alfred I want to show you the entire
> list of commands (that have been runned on all the virtual machines.) I
> used before asking my question
>
> # ip link set dev enp0s3 mtu 1532
> # batctl if add enp0s3
> # ip link set bat0 up
> # alfred -i enp0s3 -m
>
> The # ip addr of all virtual machines is [3]
> Then I opened a new console
>
> # cat /etc/hostname | alfred -s 65
> # alfred -r 65
> then I got [4] as the Examples paragraph [2] suggested
Yup this looks good. :)
> # batadv-vis --format=jsondoc
> and I got [5]
This looks kind of incomplete - there are no neighbor information at all.
>
> Question: do you have any suggestion how I can extend the jsondoc
> output, to get an output similar to [6]?
I'd suggest to create a new output type (maybe call it netjson?) next to the
existing ones. If you look in the source code [1] You'll find a couple of
hooks which are prepared exactly for this purpose.
Thanks!
Simon
[1] http://git.open-mesh.org/alfred.git/blob/HEAD:/vis/vis.c#l724
>
> Thank you for your time
>
>
> [1] http://www.open-mesh.org/projects/batman-adv/wiki/Quick-start-guide
> [2] http://downloads.open-mesh.org/batman/manpages/alfred.8.html
> [3] http://i.imgur.com/IR9pSJg.jpg
> [4] http://i.imgur.com/hEP4oV7.jpg
> [5] http://i.imgur.com/Tb1hRHl.jpg
> [6]
> https://github.com/ninuxorg/netdiff/blob/master/tests/static/batman-1%2B1.js
> on
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 181 bytes --]
next prev parent reply other threads:[~2015-09-28 17:35 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-28 16:56 [B.A.T.M.A.N.] Suggestions to get extended jsondoc alfred output Germano Massullo
2015-09-28 17:35 ` Simon Wunderlich [this message]
2015-09-28 21:10 ` Germano Massullo
2015-09-28 23:24 ` Simon Wunderlich
2015-09-29 8:45 ` Germano Massullo
2015-09-29 16:17 ` Germano Massullo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1942201.vOz91KHqBg@prime \
--to=sw@simonwunderlich.de \
--cc=b.a.t.m.a.n@lists.open-mesh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox