saltext.github.utils.gh.resource

Shared plumbing for the github resource type’s execution and state modules.

The functions here reference loader globals (__resource__, __salt__, __opts__, __context__), so consuming modules must rebind them to their own namespace via salt.utils.functools.namespaced_function():

from salt.utils.functools import namespaced_function

from saltext.github.utils.gh import resource as gh_resource

_core_args = namespaced_function(gh_resource.core_args, globals())
saltext.github.utils.gh.resource.core_args(profile=None)[source]

Return a connection for the targeted repository, along with the repository’s owner and name.

Salt’s authoring docs promise __resource__ inside state overrides, but no released Salt packs it there — in state modules, fall back to the repo.ident execution override, which does see it.