Skip to content

Commit

Permalink
#69 - remove undesired captilization
Browse files Browse the repository at this point in the history
  • Loading branch information
jaredsburrows committed Apr 23, 2019
1 parent e9a7d78 commit 7d0b78f
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 39 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ class LicenseReportTask extends LicenseReportTaskKt {
String year = pomText.inceptionYear?.text()

// Clean up and format
name = name?.capitalize()
name = name?.trim()
version = version?.trim()
description = description?.trim()
url = url?.trim()
Expand Down Expand Up @@ -139,7 +139,7 @@ class LicenseReportTask extends LicenseReportTaskKt {
}

// Sort POM information by name
projects.sort { project -> project.getName() }
projects.sort { left, right -> left.getName().compareToIgnoreCase(right.getName()) }
}

@Override protected String getName(Node pomText) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,8 @@ final class HtmlReport extends HtmlReportKt {
h3(NOTICE_LIBRARIES)
ul {
for (Map.Entry<String, List<Project>> entry : projectsMap.entrySet()) {
List<Project> sortedProjects = entry.getValue().sort {
left, right -> left.getName() <=> right.getName()
}
List<Project> sortedProjects = entry.getValue().
sort { left, right -> left.getName().compareToIgnoreCase(right.getName()) }

Project currentProject = null
Integer currentLicense = null
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -219,10 +219,10 @@ final class LicensePluginAndroidSpec extends Specification {
<h3>Notice for packages:</h3>
<ul>
<li>
<a href="#314129783">Appcompat-v7</a>
<a href="#314129783">appcompat-v7</a>
</li>
<li>
<a href="#314129783">Design</a>
<a href="#314129783">design</a>
</li>
<a name="314129783" />
<pre>${getLicenseText('apache-2.0.txt')}</pre>
Expand All @@ -235,7 +235,7 @@ final class LicensePluginAndroidSpec extends Specification {
"""
[
{
"project": "Appcompat-v7",
"project": "appcompat-v7",
"description": null,
"version": "26.1.0",
"developers": [
Expand All @@ -252,7 +252,7 @@ final class LicensePluginAndroidSpec extends Specification {
"dependency": "com.android.support:appcompat-v7:26.1.0"
},
{
"project": "Design",
"project": "design",
"description": null,
"version": "26.1.0",
"developers": [
Expand Down Expand Up @@ -346,10 +346,10 @@ final class LicensePluginAndroidSpec extends Specification {
<h3>Notice for packages:</h3>
<ul>
<li>
<a href="#314129783">Appcompat-v7</a>
<a href="#314129783">appcompat-v7</a>
</li>
<li>
<a href="#314129783">Design</a>
<a href="#314129783">design</a>
</li>
<a name="314129783" />
<pre>${getLicenseText('apache-2.0.txt')}</pre>
Expand All @@ -362,7 +362,7 @@ final class LicensePluginAndroidSpec extends Specification {
"""
[
{
"project": "Appcompat-v7",
"project": "appcompat-v7",
"description": null,
"version": "26.1.0",
"developers": [
Expand All @@ -379,7 +379,7 @@ final class LicensePluginAndroidSpec extends Specification {
"dependency": "com.android.support:appcompat-v7:26.1.0"
},
{
"project": "Design",
"project": "design",
"description": null,
"version": "26.1.0",
"developers": [
Expand Down Expand Up @@ -487,16 +487,16 @@ final class LicensePluginAndroidSpec extends Specification {
<h3>Notice for packages:</h3>
<ul>
<li>
<a href="#314129783">Appcompat-v7</a>
<a href="#314129783">appcompat-v7</a>
</li>
<li>
<a href="#314129783">Design</a>
<a href="#314129783">design</a>
</li>
<li>
<a href="#314129783">Support-annotations</a>
<a href="#314129783">support-annotations</a>
</li>
<li>
<a href="#314129783">Support-v4</a>
<a href="#314129783">support-v4</a>
</li>
<a name="314129783" />
<pre>${getLicenseText('apache-2.0.txt')}</pre>
Expand All @@ -509,7 +509,7 @@ final class LicensePluginAndroidSpec extends Specification {
"""
[
{
"project": "Appcompat-v7",
"project": "appcompat-v7",
"description": null,
"version": "26.1.0",
"developers": [
Expand All @@ -526,7 +526,7 @@ final class LicensePluginAndroidSpec extends Specification {
"dependency": "com.android.support:appcompat-v7:26.1.0"
},
{
"project": "Design",
"project": "design",
"description": null,
"version": "26.1.0",
"developers": [
Expand All @@ -543,7 +543,7 @@ final class LicensePluginAndroidSpec extends Specification {
"dependency": "com.android.support:design:26.1.0"
},
{
"project": "Support-annotations",
"project": "support-annotations",
"description": null,
"version": "26.1.0",
"developers": [
Expand All @@ -560,7 +560,7 @@ final class LicensePluginAndroidSpec extends Specification {
"dependency": "com.android.support:support-annotations:26.1.0"
},
{
"project": "Support-v4",
"project": "support-v4",
"description": null,
"version": "26.1.0",
"developers": [
Expand Down Expand Up @@ -655,7 +655,7 @@ final class LicensePluginAndroidSpec extends Specification {
<a name="1068328410" />
<pre>${getLicenseText('mit.txt')}</pre>
<li>
<a href="#314129783">Design</a>
<a href="#314129783">design</a>
</li>
<a name="314129783" />
<pre>${getLicenseText('apache-2.0.txt')}</pre>
Expand Down Expand Up @@ -685,7 +685,7 @@ final class LicensePluginAndroidSpec extends Specification {
"dependency": "pl.droidsonroids.gif:android-gif-drawable:1.2.3"
},
{
"project": "Design",
"project": "design",
"description": null,
"version": "26.1.0",
"developers": [
Expand Down Expand Up @@ -884,7 +884,7 @@ final class LicensePluginAndroidSpec extends Specification {
<h3>Notice for packages:</h3>
<ul>
<li>
<a href="#314129783">Design</a>
<a href="#314129783">design</a>
</li>
<a name="314129783" />
<pre>${getLicenseText('apache-2.0.txt')}</pre>
Expand All @@ -903,7 +903,7 @@ final class LicensePluginAndroidSpec extends Specification {
"""
[
{
"project": "Design",
"project": "design",
"description": null,
"version": "26.1.0",
"developers": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ final class LicensePluginJavaSpec extends Specification {
<h3>Notice for packages:</h3>
<ul>
<li>
<a href="#0">Firebase-core</a>
<a href="#0">firebase-core</a>
</li>
<a name="0" />
<pre>No license found</pre>
Expand All @@ -158,7 +158,7 @@ final class LicensePluginJavaSpec extends Specification {
"""
[
{
"project": "Firebase-core",
"project": "firebase-core",
"description": null,
"version": "10.0.1",
"developers": [
Expand Down Expand Up @@ -224,10 +224,10 @@ final class LicensePluginJavaSpec extends Specification {
<h3>Notice for packages:</h3>
<ul>
<li>
<a href="#314129783">Appcompat-v7</a>
<a href="#314129783">appcompat-v7</a>
</li>
<li>
<a href="#314129783">Design</a>
<a href="#314129783">design</a>
</li>
<a name="314129783" />
<pre>${getLicenseText('apache-2.0.txt')}</pre>
Expand All @@ -240,7 +240,7 @@ final class LicensePluginJavaSpec extends Specification {
"""
[
{
"project": "Appcompat-v7",
"project": "appcompat-v7",
"description": null,
"version": "26.1.0",
"developers": [
Expand All @@ -257,7 +257,7 @@ final class LicensePluginJavaSpec extends Specification {
"dependency": "com.android.support:appcompat-v7:26.1.0"
},
{
"project": "Design",
"project": "design",
"description": null,
"version": "26.1.0",
"developers": [
Expand Down Expand Up @@ -664,10 +664,10 @@ final class LicensePluginJavaSpec extends Specification {
<h3>Notice for packages:</h3>
<ul>
<li>
<a href="#314129783">Appcompat-v7</a>
<a href="#314129783">appcompat-v7</a>
</li>
<li>
<a href="#314129783">Design</a>
<a href="#314129783">design</a>
</li>
<a name="314129783" />
<pre>${getLicenseText('apache-2.0.txt')}</pre>
Expand All @@ -680,7 +680,7 @@ final class LicensePluginJavaSpec extends Specification {
"""
[
{
"project": "Appcompat-v7",
"project": "appcompat-v7",
"description": null,
"version": "26.1.0",
"developers": [
Expand All @@ -697,7 +697,7 @@ final class LicensePluginJavaSpec extends Specification {
"dependency": "com.android.support:appcompat-v7:26.1.0"
},
{
"project": "Design",
"project": "design",
"description": null,
"version": "26.1.0",
"developers": [
Expand Down Expand Up @@ -780,10 +780,10 @@ final class LicensePluginJavaSpec extends Specification {
<h3>Notice for packages:</h3>
<ul>
<li>
<a href="#314129783">Appcompat-v7</a>
<a href="#314129783">appcompat-v7</a>
</li>
<li>
<a href="#314129783">Design</a>
<a href="#314129783">design</a>
</li>
<a name="314129783" />
<pre>${getLicenseText('apache-2.0.txt')}</pre>
Expand All @@ -796,7 +796,7 @@ final class LicensePluginJavaSpec extends Specification {
"""
[
{
"project": "Appcompat-v7",
"project": "appcompat-v7",
"description": null,
"version": "26.1.0",
"developers": [
Expand All @@ -813,7 +813,7 @@ final class LicensePluginJavaSpec extends Specification {
"dependency": "com.android.support:appcompat-v7:26.1.0"
},
{
"project": "Design",
"project": "design",
"description": null,
"version": "26.1.0",
"developers": [
Expand Down

0 comments on commit 7d0b78f

Please sign in to comment.