mirror of
git://git.proxmox.com/git/pve-docs.git
synced 2025-03-11 16:58:18 +03:00
scan-adoc-refs: fix dependency computation (make it recusive)
This commit is contained in:
parent
5bf279bd97
commit
012445a518
@ -373,9 +373,21 @@ if ($generate_depends) {
|
||||
my $depends = {};
|
||||
foreach my $e (@$start_env) {
|
||||
my $env_data = $fileinfo->{include}->{$e};
|
||||
|
||||
my $add_depends;
|
||||
|
||||
$add_depends = sub {
|
||||
my ($fn, $dep) = @_;
|
||||
|
||||
$depends->{$fn}->{$dep} = 1;
|
||||
foreach my $nd (keys %{$env_data->{$dep}}) {
|
||||
&$add_depends($fn, $nd);
|
||||
}
|
||||
};
|
||||
|
||||
foreach my $fn (keys %$env_data) {
|
||||
foreach my $dep (keys %{$env_data->{$fn}}) {
|
||||
$depends->{$fn}->{$dep} = 1;
|
||||
&$add_depends($fn, $dep);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user