summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2017-01-10 09:06:50 -0700
committerSean Whitton <spwhitton@spwhitton.name>2017-01-10 09:07:26 -0700
commit5ab5457c5a444c302fd2c9f53d87fbf7c2087c25 (patch)
treed11be9a62cd87e276702d5796d7c1a29ea86e5bf
parentd70c1b3c27c699c5207921579f160a79c341a4e5 (diff)
inform the user when fail to determine desc
-rw-r--r--debian/changelog1
-rw-r--r--lib/DhMakeELPA/Command/Packaging.pm9
2 files changed, 7 insertions, 3 deletions
diff --git a/debian/changelog b/debian/changelog
index aea5aba..335d2e0 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -12,6 +12,7 @@ dh-make-elpa (0.7.0) UNRELEASED; urgency=medium
* Slightly improve the filtering of long description lines.
* If MELPA recipe download fails, fall back to using a single binary package.
* Always inform the user when we fall back to using a single binary package.
+ * Inform the user if we fail to determine the short or long description.
-- Sean Whitton <spwhitton@spwhitton.name> Sat, 29 Oct 2016 15:51:02 -0700
diff --git a/lib/DhMakeELPA/Command/Packaging.pm b/lib/DhMakeELPA/Command/Packaging.pm
index acde0c4..6c609b8 100644
--- a/lib/DhMakeELPA/Command/Packaging.pm
+++ b/lib/DhMakeELPA/Command/Packaging.pm
@@ -178,7 +178,8 @@ sub fill_vcs {
sub extract_description {
my ($self, $el_file) = @_;
my ($short_desc, $long_desc);
- my $pkg_file = $el_file =~ s/\.el/-pkg.el/r;
+ my $package = $el_file =~ s/\.el//r;
+ my $pkg_file = $package."-pkg.el";
if ( -e $pkg_file ) {
my $fh = $self->_file_r($pkg_file);
@@ -205,10 +206,12 @@ sub extract_description {
}
unless (defined $short_desc) {
- $short_desc = "couldn't determine short description"
+ print "I: couldn't determine short description for $package\n";
+ $short_desc = "couldn't determine short description";
}
unless (defined $long_desc) {
- $long_desc = "couldn't determine long description"
+ print "I: couldn't determine long description for $package\n";
+ $long_desc = "couldn't determine long description";
}
return ($short_desc, $long_desc);
}