[Scummvm-git-logs] scummvm master -> c93dacd10bde2108318f26e344dd3d3886a5da3c
Mataniko
mataniko at gmail.com
Sat Sep 5 01:22:19 UTC 2020
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
c93dacd10b CREDITS: Remove XML-WEB and other unused code
Commit: c93dacd10bde2108318f26e344dd3d3886a5da3c
https://github.com/scummvm/scummvm/commit/c93dacd10bde2108318f26e344dd3d3886a5da3c
Author: Mataniko (mataniko at gmail.com)
Date: 2020-09-04T21:20:49-04:00
Commit Message:
CREDITS: Remove XML-WEB and other unused code
Changed paths:
devtools/credits.pl
diff --git a/devtools/credits.pl b/devtools/credits.pl
index 056750d41c..a81c4d4dd8 100755
--- a/devtools/credits.pl
+++ b/devtools/credits.pl
@@ -40,17 +40,16 @@ my @section_count = ( 0, 0, 0 );
if ($#ARGV >= 0) {
$mode = "TEXT" if ($ARGV[0] eq "--text"); # AUTHORS file
- $mode = "XML-WEB" if ($ARGV[0] eq "--xml-website"); # credits.xml (for use on the website)
$mode = "CPP" if ($ARGV[0] eq "--cpp"); # credits.h (for use by about.cpp)
$mode = "XML-DOC" if ($ARGV[0] eq "--xml-docbook"); # credits.xml (DocBook)
$mode = "RTF" if ($ARGV[0] eq "--rtf"); # Credits.rtf (Mac OS X About box)
$mode = "STRONGHELP" if ($ARGV[0] eq "--stronghelp"); # AUTHORS (RISC OS StrongHelp manual)
- $mode = "YAML" if ($ARGV[0] eq "--yaml"); # YAML (Simple format)
+ $mode = "YAML" if ($ARGV[0] eq "--yaml"); # YAML (Simple format, used in the Website)
}
if ($mode eq "") {
- print STDERR "Usage: $0 [--text | --xml-website | --cpp | --xml-docbook | --rtf | --stronghelp | --yaml]\n";
- print STDERR " Just pass --text / --xml-website / --cpp / --xml-docbook / --rtf / --stronghelp / --yaml as parameter, and credits.pl\n";
+ print STDERR "Usage: $0 [--text | --cpp | --xml-docbook | --rtf | --stronghelp | --yaml]\n";
+ print STDERR " Just pass --text / --cpp / --xml-docbook / --rtf / --stronghelp / --yaml as parameter, and credits.pl\n";
print STDERR " will print out the corresponding version of the credits to stdout.\n";
exit 1;
}
@@ -68,27 +67,6 @@ sub html_entities_to_ascii {
my $text = shift;
# For now we hardcode these mappings
- # Á -> A
- # á -> a
- # é -> e
- # í -> i
- # ì -> i
- # ó -> o
- # ø -> o
- # ú -> u
- # ö -> o / oe
- # ä -> a
- # ë -> e
- # ü -> ue
- # å -> aa
- # & -> &
- # ą -> a
- # Ł -> L
- # ł -> l
- # ś -> s
- # Š -> S
- # Ľ -> L
- # ñ -> n
$text =~ s/Á/A/g;
$text =~ s/á/a/g;
$text =~ s/é/e/g;
@@ -236,9 +214,7 @@ sub html_entities_to_rtf {
sub begin_credits {
my $title = shift;
- if ($mode eq "TEXT") {
- #print html_entities_to_ascii($title)."\n";
- } elsif ($mode eq "RTF") {
+ if ($mode eq "RTF") {
print '{\rtf1\mac\ansicpg10000' . "\n";
print '{\fonttbl\f0\fswiss\fcharset77 Helvetica-Bold;\f1\fswiss\fcharset77 Helvetica;}' . "\n";
print '{\colortbl;\red255\green255\blue255;\red0\green128\blue0;\red128\green128\blue128;}' . "\n";
@@ -260,10 +236,6 @@ sub begin_credits {
print " <colspec colname='name' colwidth='4cm'/>\n";
print " <colspec colname='job'/>\n";
print " <tbody>\n";
- } elsif ($mode eq "XML-WEB") {
- print "<?xml version='1.0'?>\n";
- print "<!-- This file was generated by credits.pl. Do not edit by hand! -->\n";
- print "<credits>\n";
} elsif ($mode eq "YAML") {
print "# This file was generated by credits.pl. Do not edit by hand!\n";
print "credits:\n";
@@ -284,8 +256,6 @@ sub end_credits {
print " </tgroup>\n";
print " </informaltable>\n";
print "</appendix>\n";
- } elsif ($mode eq "XML-WEB") {
- print "</credits>\n";
}
}
@@ -340,23 +310,6 @@ sub begin_section {
print " <row><entry namest='start' nameend='job'>";
print "<emphasis role='bold'>" . $title . ":</emphasis>";
print "</entry></row>\n";
- } elsif ($mode eq "XML-WEB") {
- if ($section_level eq 0) {
- print "\t<section>\n";
- print "\t\t<title>" . $title . "</title>\n";
- if ($anchor) {
- print "\t\t<anchor>" . $anchor . "</anchor>\n";
- }
- } elsif ($section_level eq 1) {
- print "\t\t<subsection>\n";
- print "\t\t\t<title>" . $title . "</title>\n";
- if ($anchor) {
- print "\t\t\t<anchor>" . $anchor . "</anchor>\n";
- }
- } else {
- #print "\t\t\t<group>" . $title . "</group>\n";
- #print "\t\t\t\t<name>" . $title . "</name>\n";
- }
} elsif ($mode eq "YAML") {
my $key = "section:\n";
$indent = " " . (" " x $section_level);
@@ -407,14 +360,6 @@ sub end_section {
print '"",' . "\n";
} elsif ($mode eq "XML-DOC") {
print " <row><entry namest='start' nameend='job'> </entry></row>\n\n";
- } elsif ($mode eq "XML-WEB") {
- if ($section_level eq 0) {
- print "\t</section>\n";
- } elsif ($section_level eq 1) {
- print "\t\t</subsection>\n";
- } else {
- #print "\t\t\t</group>\n";
- }
}
}
@@ -422,11 +367,7 @@ sub begin_persons {
my $title = shift;
my $level = shift;
- if ($mode eq "XML-WEB") {
- print "\t\t\t<group>\n";
- print "\t\t\t\t<name>" . $title . "</name>\n";
- #print "\t\t\t\t<persons>\n";
- } elsif ($mode eq "YAML") {
+ if ($mode eq "YAML") {
$group_indent = $level eq 1 ? " " : " " . (" " x $section_level);
if ($group_started == 0) {
print $group_indent . "group:\n";
@@ -443,9 +384,6 @@ sub end_persons {
print "\n";
} elsif ($mode eq "RTF") {
# nothing
- } elsif ($mode eq "XML-WEB") {
- #print "\t\t\t\t</persons>\n";
- print "\t\t\t</group>\n";
} elsif ($mode eq "STRONGHELP") {
print "\n";
} elsif ($mode eq "YAML") {
@@ -508,13 +446,6 @@ sub add_person {
$name = $nick if $name eq "";
print " <row><entry namest='name'>" . $name . "</entry>";
print "<entry>" . $desc . "</entry></row>\n";
- } elsif ($mode eq "XML-WEB") {
- $name = "???" if $name eq "";
- print "\t\t\t\t<person>\n";
- print "\t\t\t\t\t<name>" . $name . "</name>\n";
- print "\t\t\t\t\t<alias>" . $nick . "</alias>\n";
- print "\t\t\t\t\t<description>" . $desc . "</description>\n";
- print "\t\t\t\t</person>\n";
} elsif ($mode eq "YAML") {
$indent = $group_indent . " ";
@@ -562,8 +493,6 @@ sub add_paragraph {
} elsif ($mode eq "XML-DOC") {
print " <row><entry namest='start' nameend='job'>" . $text . "</entry></row>\n";
print " <row><entry namest='start' nameend='job'> </entry></row>\n\n";
- } elsif ($mode eq "XML-WEB") {
- print "\t\t<paragraph>" . $text . "</paragraph>\n";
} elsif ($mode eq "YAML") {
$indent = " " . (" " x $section_level);
if ($paragraph_started eq 0) {
More information about the Scummvm-git-logs
mailing list