diff --git a/src/python/jw/pkg/cmds/projects/BaseCmdPkgRelations.py b/src/python/jw/pkg/cmds/projects/BaseCmdPkgRelations.py index cb5028dd..0683e748 100644 --- a/src/python/jw/pkg/cmds/projects/BaseCmdPkgRelations.py +++ b/src/python/jw/pkg/cmds/projects/BaseCmdPkgRelations.py @@ -33,6 +33,7 @@ class BaseCmdPkgRelations(Cmd): quote: bool = False, skip_excluded: bool = False, hide_self = False, + hide_jw_pkg = False ) -> list[str]: if subsections is None: @@ -81,6 +82,8 @@ class BaseCmdPkgRelations(Cmd): if subsec == 'jw': if recursive and not dep_name in visited and not dep_name in cur_pkgs: cur_pkgs.append(dep_name) + if hide_jw_pkg: + continue if len(dep) == 3: if dont_expand_version_macros and dep_name in cur_pkgs: version = dep[2] @@ -160,6 +163,7 @@ class BaseCmdPkgRelations(Cmd): quote = args.quote, skip_excluded = args.skip_excluded, hide_self = args.hide_self, + hide_jw_pkg = args.hide_jw_pkg, ) ) @@ -194,6 +198,8 @@ class BaseCmdPkgRelations(Cmd): help='Don\'t consider or output modules matching the os cascade in their [build].exclude config') parser.add_argument('--hide-self', action='store_true', default=False, help='Don\'t include any of the projects listed in in the output') + parser.add_argument('--hide-jw-pkg', action='store_true', default=False, + help='Don\'t include packages from requires.jw in the output') parser.add_argument('--quote', action='store_true', default=False, help='Put double quotes around each listed dependency')