@matheusbsbs / matheus-bagliano / commits / 0bf15e7438
Fork 0

Documentation: lost-found is now deprecated.

This makes it possible to mark commands that are deprecated in the command list of the primary manual page git(7), and uses it to mark "git lost-found" and "git tar-tree" as deprecated. Signed-off-by: Junio C Hamano <gitster@pobox.com>

Junio C Hamano committed Nov 8, 2007 at 17:21 UTC 0bf15e743826774c2b76858e274efc4211522ec9
1 file changed +11 -7
Documentation/cmd-list.perl
+11 -7
@@ -3,7 +3,8 @@
3 use File::Compare qw(compare);
4
5 sub format_one {
6 - my ($out, $name) = @_;
6 + my ($out, $nameattr) = @_;
7 + my ($name, $attr) = @$nameattr;
8 my ($state, $description);
9 $state = 0;
10 open I, '<', "$name.txt" or die "No such file $name.txt";
@@ -26,8 +27,11 @@ sub format_one {
27 die "No description found in $name.txt";
28 }
29 if (my ($verify_name, $text) = ($description =~ /^($name) - (.*)/)) {
29 - print $out "gitlink:$name\[1\]::\n";
30 - print $out "\t$text.\n\n";
30 + print $out "gitlink:$name\[1\]::\n\t";
31 + if ($attr) {
32 + print $out "($attr) ";
33 + }
34 + print $out "$text.\n\n";
35 }
36 else {
37 die "Description does not match $name: $description";
@@ -39,8 +43,8 @@ while (<DATA>) {
43 next if /^#/;
44
45 chomp;
42 - my ($name, $cat) = /^(\S+)\s+(.*)$/;
43 - push @{$cmds{$cat}}, $name;
46 + my ($name, $cat, $attr) = /^(\S+)\s+(.*?)(?:\s+(.*))?$/;
47 + push @{$cmds{$cat}}, [$name, $attr];
48 }
49
50 for my $cat (qw(ancillaryinterrogators
@@ -126,7 +130,7 @@ git-instaweb ancillaryinterrogators
130 gitk mainporcelain
131 git-local-fetch synchingrepositories
132 git-log mainporcelain
129 -git-lost-found ancillarymanipulators
133 +git-lost-found ancillarymanipulators deprecated
134 git-ls-files plumbinginterrogators
135 git-ls-remote plumbinginterrogators
136 git-ls-tree plumbinginterrogators
@@ -187,7 +191,7 @@ git-submodule mainporcelain
191 git-svn foreignscminterface
192 git-symbolic-ref plumbingmanipulators
193 git-tag mainporcelain
190 -git-tar-tree plumbinginterrogators
194 +git-tar-tree plumbinginterrogators deprecated
195 git-unpack-file plumbinginterrogators
196 git-unpack-objects plumbingmanipulators
197 git-update-index plumbingmanipulators