Skip to content

Commit c4fd50a

Browse files
committed
docs: improve README a tiny bit
1 parent 3e2a2ea commit c4fd50a

File tree

1 file changed

+23
-9
lines changed

1 file changed

+23
-9
lines changed

README.md

Lines changed: 23 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,29 @@ Did you ever got to implement XML parser? Perhaps for atom, or scap? You may hav
1515
cool to automatically generate XML parser based on XSD definition? That's exactly what we
1616
are up to here.
1717

18-
### Related projects:
19-
- ![Metaschema](https://github.com/gocomply/metaschema) - generate golang code based on NIST metaschema input
20-
- ![SCAP](https://github.com/gocomply/scap) - parsers of NIST SCAP family of standards
18+
## Installation
2119

22-
## Exemplary Usage
20+
```shell
21+
go install github.com/gocomply/xsd2go/cli/gocomply_xsd2go@latest
22+
```
23+
24+
## Usage
25+
26+
```
27+
gocomply_xsd2go convert --help
28+
NAME:
29+
gocomply_xsd2go convert - convert XSD to golang code to parse xml files generated by given xsd
30+
31+
USAGE:
32+
gocomply_xsd2go convert [command options] XSD-FILE GO-MODULE-IMPORT OUTPUT-DIR
2333
34+
OPTIONS:
35+
--xmlns-override value Allows to explicitly set gopackage name for given XMLNS. Example: --xmlns-override='http://www.w3.org/2000/09/xmldsig#=xml_signatures'
2436
```
37+
38+
## Exemplary Usage
39+
40+
```shell
2541
# Acquire latest some XSD file you want to convert - for instance XCCDF 1.2
2642
git clone --depth 1 https://github.com/openscap/openscap
2743
# Parse XSD schema and generate golang structs
@@ -31,8 +47,6 @@ git clone --depth 1 https://github.com/openscap/openscap
3147
github.com/gocomply/scap pkg/scap/models
3248
```
3349

34-
## Installation
35-
36-
```
37-
go get -u -v github.com/gocomply/xsd2go/cli/gocomply_xsd2go
38-
```
50+
### Related projects:
51+
- ![Metaschema](https://github.com/gocomply/metaschema) - generate golang code based on NIST metaschema input
52+
- ![SCAP](https://github.com/gocomply/scap) - parsers of NIST SCAP family of standards

0 commit comments

Comments
 (0)