Add swh-graph-convert to serialize small graphs to JSON
This can be used to get a textual representation of small graphs, which can then be shared and used in tests or examples.
For example, the example dataset looks like this:
{"swhids":["swh:1:ori:8f50d3f60eae370ddbf85c86219c55108a350165","swh:1:snp:0000000000000000000000000000000000000022","swh:1:ori:83404f995118bd25774f4ac14422a8f175e7a054","swh:1:rev:0000000000000000000000000000000000000009","swh:1:rel:0000000000000000000000000000000000000010","swh:1:snp:0000000000000000000000000000000000000020","swh:1:rev:0000000000000000000000000000000000000003","swh:1:dir:0000000000000000000000000000000000000002","swh:1:cnt:0000000000000000000000000000000000000005","swh:1:dir:0000000000000000000000000000000000000006","swh:1:cnt:0000000000000000000000000000000000000004","swh:1:cnt:0000000000000000000000000000000000000001","swh:1:dir:0000000000000000000000000000000000000008","swh:1:cnt:0000000000000000000000000000000000000007","swh:1:dir:0000000000000000000000000000000000000012","swh:1:cnt:0000000000000000000000000000000000000011","swh:1:rev:0000000000000000000000000000000000000013","swh:1:dir:0000000000000000000000000000000000000016","swh:1:cnt:0000000000000000000000000000000000000015","swh:1:rel:0000000000000000000000000000000000000021","swh:1:rev:0000000000000000000000000000000000000018","swh:1:rel:0000000000000000000000000000000000000019","swh:1:dir:0000000000000000000000000000000000000017","swh:1:cnt:0000000000000000000000000000000000000014"],"contents":null,"label_names":null,"persons":null,"strings":null,"timestamps":null,"arcs":[[[1,[43772814136]]],[[3,[56]],[4,[40]],[19,[48]]],[[5,[43772814136]]],[[6,[]],[12,[]]],[[3,[]]],[[3,[56]],[4,[40]]],[[7,[]]],[[11,[1]]],[],[[8,[33]],[10,[1]]],[],[],[[9,[66]],[11,[1]],[13,[33]]],[],[[12,[26]],[15,[1]]],[],[[3,[]],[14,[]]],[[18,[9]]],[],[[20,[]]],[[16,[]],[22,[]]],[[20,[]]],[[17,[18]],[23,[9]]],[]]}
I am planning to use this in swh-provenance's tests instead of committing the binary files.