From be16bf69a8e66f3eb42bb0789ff210e6d36ddee3 Mon Sep 17 00:00:00 2001 From: David Steele Date: Mon, 29 Jun 2020 15:07:17 -0400 Subject: [PATCH] Remove internal commands from HTML and man command references. Some of these commands will be made public in the future but for now their interfaces are not stable so they remain internal. --- doc/lib/pgBackRestDoc/Common/DocConfig.pm | 8 ++++++++ doc/xml/release.xml | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/doc/lib/pgBackRestDoc/Common/DocConfig.pm b/doc/lib/pgBackRestDoc/Common/DocConfig.pm index 1a002aced..3de4e41a4 100644 --- a/doc/lib/pgBackRestDoc/Common/DocConfig.pm +++ b/doc/lib/pgBackRestDoc/Common/DocConfig.pm @@ -27,6 +27,7 @@ use constant CONFIG_HELP_DEFAULT => 'default' use constant CONFIG_HELP_DESCRIPTION => 'description'; push @EXPORT, qw(CONFIG_HELP_DESCRIPTION); use constant CONFIG_HELP_EXAMPLE => 'example'; +use constant CONFIG_HELP_INTERNAL => 'internal'; use constant CONFIG_HELP_NAME => 'name'; use constant CONFIG_HELP_NAME_ALT => 'name-alt'; push @EXPORT, qw(CONFIG_HELP_NAME_ALT); @@ -203,6 +204,7 @@ sub process $$oCommand{&CONFIG_HELP_SUMMARY} = $oCommandDoc->nodeGet('summary')->textGet(); $$oCommand{&CONFIG_HELP_DESCRIPTION} = $oCommandDoc->textGet(); + $oCommand->{&CONFIG_HELP_INTERNAL} = cfgDefineCommand()->{$strCommand}{&CFGDEF_INTERNAL}; } # Iterate through all options @@ -425,6 +427,9 @@ sub manGet foreach my $strCommand (sort(keys(%{$$hConfig{&CONFIG_HELP_COMMAND}}))) { + # Skip internal commands + next if $hConfig->{&CONFIG_HELP_COMMAND}{$strCommand}{&CONFIG_HELP_INTERNAL}; + my $hCommand = $$hConfig{&CONFIG_HELP_COMMAND}{$strCommand}; $iCommandMaxLen = length($strCommand) > $iCommandMaxLen ? length($strCommand) : $iCommandMaxLen; @@ -676,6 +681,9 @@ sub helpCommandDocGet foreach my $strCommand (sort(keys(%{$$oConfigHash{&CONFIG_HELP_COMMAND}}))) { + # Skip internal commands + next if $oConfigHash->{&CONFIG_HELP_COMMAND}{$strCommand}{&CONFIG_HELP_INTERNAL}; + my $oCommandHash = $$oConfigHash{&CONFIG_HELP_COMMAND}{$strCommand}; my $oSectionElement = $oDoc->nodeAdd('section', undef, {id => "command-${strCommand}"}); diff --git a/doc/xml/release.xml b/doc/xml/release.xml index da2616d1d..8c7355571 100644 --- a/doc/xml/release.xml +++ b/doc/xml/release.xml @@ -106,6 +106,14 @@

Fix incorrect example for repo-retention-full-type option.

+ + + + + + +

Remove internal commands from HTML and man command references.

+