mirror of
ssh://git.janware.com/janware/proj/jw-pkg
synced 2026-04-24 17:23:36 +02:00
cmds.projects.BaseCmdPkgRelations: Add --hide-jw-pkg
Support --hide-jw-pkg. This is a step towards replacing required-os-pkg, which leaves out packages from pkg.requires.jw sections. Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
parent
ad0e03f14c
commit
40511947c9
1 changed files with 6 additions and 0 deletions
|
|
@ -33,6 +33,7 @@ class BaseCmdPkgRelations(Cmd):
|
||||||
quote: bool = False,
|
quote: bool = False,
|
||||||
skip_excluded: bool = False,
|
skip_excluded: bool = False,
|
||||||
hide_self = False,
|
hide_self = False,
|
||||||
|
hide_jw_pkg = False
|
||||||
) -> list[str]:
|
) -> list[str]:
|
||||||
|
|
||||||
if subsections is None:
|
if subsections is None:
|
||||||
|
|
@ -81,6 +82,8 @@ class BaseCmdPkgRelations(Cmd):
|
||||||
if subsec == 'jw':
|
if subsec == 'jw':
|
||||||
if recursive and not dep_name in visited and not dep_name in cur_pkgs:
|
if recursive and not dep_name in visited and not dep_name in cur_pkgs:
|
||||||
cur_pkgs.append(dep_name)
|
cur_pkgs.append(dep_name)
|
||||||
|
if hide_jw_pkg:
|
||||||
|
continue
|
||||||
if len(dep) == 3:
|
if len(dep) == 3:
|
||||||
if dont_expand_version_macros and dep_name in cur_pkgs:
|
if dont_expand_version_macros and dep_name in cur_pkgs:
|
||||||
version = dep[2]
|
version = dep[2]
|
||||||
|
|
@ -160,6 +163,7 @@ class BaseCmdPkgRelations(Cmd):
|
||||||
quote = args.quote,
|
quote = args.quote,
|
||||||
skip_excluded = args.skip_excluded,
|
skip_excluded = args.skip_excluded,
|
||||||
hide_self = args.hide_self,
|
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')
|
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,
|
parser.add_argument('--hide-self', action='store_true', default=False,
|
||||||
help='Don\'t include any of the projects listed in <modules> in the output')
|
help='Don\'t include any of the projects listed in <modules> 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,
|
parser.add_argument('--quote', action='store_true', default=False,
|
||||||
help='Put double quotes around each listed dependency')
|
help='Put double quotes around each listed dependency')
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue