jdiegodcp / ramlfications

Python parser for RAML
https://ramlfications.readthedocs.org
Apache License 2.0
234 stars 50 forks source link

Tree prints out multiple of the same endpoint when verbose = 0 #49

Open econchick opened 8 years ago

econchick commented 8 years ago

An example RAML file:

# <-- snip -->
/foo:
  get:
    description: get foo
  post:
    description: post foo
  put:
    description: put foo

When running tree on the RAML file, it would print out like so:

$ ramlfications tree api.raml
# <--snip-->
|- /foo
|- /foo
|- /foo

I it to just be condensed to just one /foo.

With increased verbosity, it's a bit more understandable:

$ ramlfications tree api.raml
# <--snip-->
|- /foo
  ⌙ GET
|- /foo
  ⌙ POST
|- /foo
  ⌙ PUT

Still isn't too pretty; maybe it should be more like:

$ ramlfications tree api.raml
# <--snip-->
|- /foo
  ⌙ GET
  ⌙ POST
  ⌙ PUT