<pre style='margin:0'>
Renee Otten (reneeotten) pushed a commit to branch master
in repository upt-macports.

</pre>
<p><a href="https://github.com/macports/upt-macports/commit/dac134061ab66bf7174b2f17fff2ca4e61400eb0">https://github.com/macports/upt-macports/commit/dac134061ab66bf7174b2f17fff2ca4e61400eb0</a></p>
<pre style="white-space: pre; background: #F8F8F8">The following commit(s) were added to refs/heads/master by this push:
<span style='display:block; white-space:pre;color:#404040;'>     new dac1340  Fix ruby Portfile
</span>dac1340 is described below

<span style='display:block; white-space:pre;color:#808000;'>commit dac134061ab66bf7174b2f17fff2ca4e61400eb0
</span>Author: Korusuke <karan.sheth@somaiya.edu>
AuthorDate: Thu Jun 27 10:46:34 2019 +0530

<span style='display:block; white-space:pre;color:#404040;'>    Fix ruby Portfile
</span><span style='display:block; white-space:pre;color:#404040;'>    
</span><span style='display:block; white-space:pre;color:#404040;'>    Fixes #36
</span>---
 upt_macports/templates/base.Portfile        | 2 +-
 upt_macports/templates/ruby.Portfile        | 6 +++---
 upt_macports/tests/test_macports_package.py | 6 ++++++
 upt_macports/upt_macports.py                | 6 +++++-
 4 files changed, 15 insertions(+), 5 deletions(-)

<span style='display:block; white-space:pre;color:#808080;'>diff --git a/upt_macports/templates/base.Portfile b/upt_macports/templates/base.Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 685b4fb..4a881a3 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/upt_macports/templates/base.Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/upt_macports/templates/base.Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -24,7 +24,7 @@ license             {{ pkg.licenses }}
</span> # maintainers         {example.org:julesverne @github-handle} openmaintainer
 maintainers         nomaintainer
 
<span style='display:block; white-space:pre;background:#ffe0e0;'>-description         {{ pkg.upt_pkg.summary }}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+description         {{ pkg.upt_pkg.summary|trim|replace('\n',' \\\n')|indent(20, false) }}
</span> long_description    ${description}
 
 {% block dist_info %}
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/upt_macports/templates/ruby.Portfile b/upt_macports/templates/ruby.Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 9e779c2..99a198e 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/upt_macports/templates/ruby.Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/upt_macports/templates/ruby.Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -4,8 +4,8 @@
</span> PortGroup           ruby 1.0
 {% endblock %}
 {% block nameversion %}
<span style='display:block; white-space:pre;background:#ffe0e0;'>-ruby.setup          {{ pkg._pkgname() }} {{ pkg.upt_pkg.version }} gem {} rubygems
</span> ruby.branches       2.5 2.6
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ruby.setup          {{ pkg._pkgname() }} {{ pkg.upt_pkg.version }} gem {} rubygems
</span> revision            0
 {% endblock %}
 
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -15,7 +15,7 @@ if {${subport} ne ${name}} {
</span>     {% if pkg.upt_pkg.requirements.run %}
     depends_lib-append \
                     {% for i in pkg.upt_pkg.requirements.run|sort(attribute='name') %}
<span style='display:block; white-space:pre;background:#ffe0e0;'>-                    port:rb${ruby.version}-{{i.name}}{% if not loop.last %} \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                    port:rb${ruby.suffix}-{{i.name}}{% if not loop.last %} \
</span>                     {% endif %}
                     {% endfor %}
     {% endif %}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -24,7 +24,7 @@ if {${subport} ne ${name}} {
</span>     {% if pkg.upt_pkg.requirements.test %}
     depends_test-append \
                     {% for i in pkg.upt_pkg.requirements.test|sort(attribute='name') %}
<span style='display:block; white-space:pre;background:#ffe0e0;'>-                    port:rb${ruby.version}-{{i.name}}{% if not loop.last %} \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                    port:rb${ruby.suffix}-{{i.name}}{% if not loop.last %} \
</span>                     {% endif %}
                     {% endfor %}
     {% endif %}
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/upt_macports/tests/test_macports_package.py b/upt_macports/tests/test_macports_package.py
</span><span style='display:block; white-space:pre;color:#808080;'>index 57bdb6b..0938a31 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/upt_macports/tests/test_macports_package.py
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/upt_macports/tests/test_macports_package.py
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -80,16 +80,22 @@ class TestMacPortsPackageArchiveType(unittest.TestCase):
</span> 
     def test_no_archive(self):
         self.package.upt_pkg.archives = []
<span style='display:block; white-space:pre;background:#e0ffe0;'>+        self.package.upt_pkg.frontend = 'frontend'
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+        self.package.archive_format = upt.ArchiveType.SOURCE_TARGZ
</span>         expected = 'unknown'
         self.assertEqual(self.package.archive_type, expected)
 
     def test_known_archive(self):
         self.package.upt_pkg.archives = [upt.Archive("url.co/dir/file.tar.gz")]
<span style='display:block; white-space:pre;background:#e0ffe0;'>+        self.package.upt_pkg.frontend = 'frontend'
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+        self.package.archive_format = upt.ArchiveType.SOURCE_TARGZ
</span>         expected = 'gz'
         self.assertEqual(self.package.archive_type, expected)
 
     def test_unknown_archive(self):
         self.package.upt_pkg.archives = [upt.Archive("url.co/dir/file.rar")]
<span style='display:block; white-space:pre;background:#e0ffe0;'>+        self.package.upt_pkg.frontend = 'frontend'
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+        self.package.archive_format = upt.ArchiveType.RUBYGEM
</span>         expected = 'unknown'
         self.assertEqual(self.package.archive_type, expected)
 
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/upt_macports/upt_macports.py b/upt_macports/upt_macports.py
</span><span style='display:block; white-space:pre;color:#808080;'>index 55cf2db..b1c0903 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/upt_macports/upt_macports.py
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/upt_macports/upt_macports.py
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -79,7 +79,8 @@ class MacPortsPackage(object):
</span>             'xz': 'xz'
         }
         try:
<span style='display:block; white-space:pre;background:#ffe0e0;'>-            archive_name = self.upt_pkg.get_archive().filename
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+            archive_name = self.upt_pkg.get_archive(
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                self.archive_format).filename
</span>             archive_type = archive_name.split('.')[-1]
             return archive_keyword.get(archive_type, 'unknown')
 
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -90,6 +91,7 @@ class MacPortsPackage(object):
</span> 
 class MacPortsPythonPackage(MacPortsPackage):
     template = 'python.Portfile'
<span style='display:block; white-space:pre;background:#e0ffe0;'>+    archive_format = upt.ArchiveType.SOURCE_TARGZ
</span> 
     def _pkgname(self):
         macports_name = self._normalized_macports_name(self.upt_pkg.name)
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -121,6 +123,7 @@ class MacPortsNpmPackage(MacPortsPackage):
</span> 
 class MacPortsPerlPackage(MacPortsPackage):
     template = 'perl.Portfile'
<span style='display:block; white-space:pre;background:#e0ffe0;'>+    archive_format = upt.ArchiveType.SOURCE_TARGZ
</span> 
     def _pkgname(self):
         macports_name = self._normalized_macports_name(self.upt_pkg.name)
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -157,6 +160,7 @@ class MacPortsPerlPackage(MacPortsPackage):
</span> 
 class MacPortsRubyPackage(MacPortsPackage):
     template = 'ruby.Portfile'
<span style='display:block; white-space:pre;background:#e0ffe0;'>+    archive_format = upt.ArchiveType.RUBYGEM
</span> 
     def _pkgname(self):
         macports_name = self._normalized_macports_name(self.upt_pkg.name)
</pre><pre style='margin:0'>

</pre>