We use the compact syntax of Relax NG to define the format specifications.
Follow these instructions to convert the source files (.rnc files) into destination files (.xsd and .rng).
Install the trang utility, also available on Homebrew for Mac OS.
Run this command to for example convert gexf.rnc
into gexf.xsd
:
trang -I rnc -O xsd 1.3/gexf.rnc 1.3/gexf.xsd
Execute the provided build.sh
script with the folder name, e.g.
build.sh 1.3
To validate a GEXF file against the specification execute the provided validate.sh
script with the specs folder name, e.g.
validate.sh 1.3 test.gexf
Alternatively, one can validate using xmllint with the following command:
xmllint --noout --schema 1.3/gexf.xsd test.gexf