Skip to content

Commit

Permalink
Item13649: Remove default for License too
Browse files Browse the repository at this point in the history
And add warnings if no License or Copyright are set in the PackageForm.
  • Loading branch information
gac410 committed Sep 5, 2015
1 parent cc3e182 commit 994f94b
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions BuildContrib/lib/Foswiki/Contrib/BuildContrib/Targets/stage.pm
Expand Up @@ -37,12 +37,11 @@ sub form_repair {

# Extract form data from text
my %data = (
Author => "ProjectContributor",
Release => '%$RELEASE%',
Version => '%$VERSION%',
Copyright => 'Foswiki Contributors, All Rights Reserved',
License =>
'GPL ([[http://www.gnu.org/copyleft/gpl.html][GNU General Public License]])',
Author => "ProjectContributor",
Release => '%$RELEASE%',
Version => '%$VERSION%',
Copyright => '',
License => '',
Home => 'http://foswiki.org/Extensions/%$ROOTMODULE%',
Support => 'http://foswiki.org/Support/%$ROOTMODULE%',
Repository => 'https://github.com/foswiki/%$ROOTMODULE%'
Expand Down Expand Up @@ -72,6 +71,10 @@ sub form_repair {
}

#print STDERR "FIELD $field DATA $data{$field}\n";
print STDERR "WARNING: no Copyright set in the PackageForm.\n"
if ( $field eq 'Copyright' && !$data{$field} );
print STDERR "WARNING: no License set in the PackageForm.\n"
if ( $field eq 'License' && !$data{$field} );
$form .= "\%META:FIELD{name=\"$field\" ";
$form .= "title=\"$field\" value=\"$data{$field}\"}%\n";
}
Expand Down

0 comments on commit 994f94b

Please sign in to comment.