SpecDetails in a documentation plugin #1836
haroon-sheikh
started this conversation in
General
Replies: 1 comment 6 replies
-
@BugDiver can you give me hand with this please? |
Beta Was this translation helpful? Give feedback.
6 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi All,
I'm currently writing a documentation type plugin similar to spectacle.
Can you please help me understand how
gauge_messages.SpecDetails
are populated when implementingfunc (h *handler) GenerateDocs(c context.Context, m *gauge_messages.SpecDetails) (*gauge_messages.Empty, error)
It's populated when invoking the plugin with the spec path, i.e.
gauge docs 'plugin_name' 'specs_dir'
but I'm trying to figure out how I can get this populated without the specs_dir argument when the plugin is run from the projectroot...os.Getenv("GAUGE_SPEC_DIRS")
gives the correct project specs path butm.GetDetails()
comes out as empty.Any pointers on what I'm missing here?
GetProtoSpecs(m)
is returning an empty list when spec_dir argument not given on run.I think the problem is
gauge_specs_dir
default which is being set to relative pathspecs
. And running the plugin with relative path argument also returns empty SpecDetails ... e.g.gauge docs newplugin specs/
fails butgauge docs newplugin /abs/path/to/specs/
works as expected.Beta Was this translation helpful? Give feedback.
All reactions