You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tapestry.apache.org by th...@apache.org on 2022/03/18 02:38:25 UTC

[tapestry-5] branch master updated (b0c351a -> 54622bb)

This is an automated email from the ASF dual-hosted git repository.

thiagohp pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/tapestry-5.git.


    from b0c351a  TAP5-2703: Quickstart: navbar collapse button doesn't work
     new c607b21  TAP5-2699: Fixing artifact publication in Gradle 7
     new 4280a70  TAP5-2699: Upgrading to Gradle 7.4.1
     new 54622bb  TAP5-2703: Quickstart navbar collapse button not working

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 build.gradle                                       | 120 +++++++++++++--------
 gradle/wrapper/gradle-wrapper.properties           |   2 +-
 .../{LICENSE-ASM-7_0.txt => LICENSE-ASM-9_2.txt}   |   0
 plastic/build.gradle                               |   2 +-
 quickstart/build.gradle                            |   4 +-
 .../META-INF/maven/archetype-metadata.xml          |   1 +
 .../src/main/java/components/Layout.java           |   2 +-
 .../META-INF/modules/components/Layout.js          |   3 +
 .../src/test/java/tapestry/RunWithJetty.java       |  14 +++
 tapestry-webresources/build.gradle                 |   3 +
 10 files changed, 101 insertions(+), 50 deletions(-)
 rename plastic/{LICENSE-ASM-7_0.txt => LICENSE-ASM-9_2.txt} (100%)
 create mode 100644 quickstart/src/main/resources/archetype-resources/src/main/resources/META-INF/modules/components/Layout.js
 create mode 100644 quickstart/src/main/resources/archetype-resources/src/test/java/tapestry/RunWithJetty.java

[tapestry-5] 02/03: TAP5-2699: Upgrading to Gradle 7.4.1

Posted by th...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

thiagohp pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tapestry-5.git

commit 4280a70df1e8b6d919e1fc7c37137bbfbbf193e3
Author: Thiago H. de Paula Figueiredo <th...@arsmachina.com.br>
AuthorDate: Fri Mar 11 23:50:07 2022 -0300

    TAP5-2699: Upgrading to Gradle 7.4.1
---
 gradle/wrapper/gradle-wrapper.properties | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties
index 41dfb87..00e33ed 100644
--- a/gradle/wrapper/gradle-wrapper.properties
+++ b/gradle/wrapper/gradle-wrapper.properties
@@ -1,5 +1,5 @@
 distributionBase=GRADLE_USER_HOME
 distributionPath=wrapper/dists
-distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-bin.zip
+distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.1-bin.zip
 zipStoreBase=GRADLE_USER_HOME
 zipStorePath=wrapper/dists

[tapestry-5] 01/03: TAP5-2699: Fixing artifact publication in Gradle 7

Posted by th...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

thiagohp pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tapestry-5.git

commit c607b21f7f21fe42d0b8b2332edb7aab9288db21
Author: Thiago H. de Paula Figueiredo <th...@arsmachina.com.br>
AuthorDate: Fri Mar 11 23:49:24 2022 -0300

    TAP5-2699: Fixing artifact publication in Gradle 7
---
 build.gradle                                       | 120 +++++++++++++--------
 .../{LICENSE-ASM-7_0.txt => LICENSE-ASM-9_2.txt}   |   0
 plastic/build.gradle                               |   2 +-
 tapestry-webresources/build.gradle                 |   3 +
 4 files changed, 79 insertions(+), 46 deletions(-)

diff --git a/build.gradle b/build.gradle
index d037de0..7f01347 100755
--- a/build.gradle
+++ b/build.gradle
@@ -3,6 +3,7 @@ description = "Apache Tapestry 5 Project"
 import org.apache.tools.ant.filters.ReplaceTokens
 
 apply plugin: "base"
+apply plugin: "maven-publish"
 
 apply from: "ssh.gradle"
 apply from: "md5.gradle"
@@ -82,6 +83,7 @@ allprojects {
     apply plugin: "idea"
 
     repositories {
+        mavenLocal()
         mavenCentral()
 
         // All things JBoss/Hibernate
@@ -135,34 +137,18 @@ subprojects {
     def specifyMaxPermSize = jdkVersion ==~ /1\.[67].+/
 
     apply plugin: "maven-publish"  // for deployment
-    
-    publishing {
-        publications {
-            maven(MavenPublication) {
-                version = parent.version
-                groupId = "org.apache.tapestry"
-                // from components.java
-            }
-        }
-    }
-    
-    if (doSign) {
-        apply plugin: "signing"
-        signing {
-            // sign publishing.publications.mavenJava
-            sign publishing.publications.maven
-        }
-    }
 
     configurations {
         provided
     }
 
+    apply plugin: "java"
     apply plugin: "java-library"
     apply plugin: "groovy" // mostly for testing
 
     apply plugin: "project-report"
     apply plugin: "jacoco"
+    apply plugin: "base"
     
     jacoco {
         toolVersion = "0.8.7"
@@ -233,7 +219,7 @@ subprojects {
 
         environment.LANG = 'en_US.UTF-8'
         
-        if (continuousIntegrationBuild){
+        if (continuousIntegrationBuild) {
           // Travis runs our builds with TERM=dumb and kills it if we don't produce any
           // output for 10 minutes, so we log some task execution progress 
 
@@ -267,6 +253,8 @@ subprojects {
         	}
         }
     }
+    
+    assemble.dependsOn(processResources, compileJava, jar)
 
     task sourcesJar(type: Jar) {
         dependsOn classes
@@ -283,7 +271,6 @@ subprojects {
         meta sourcesJar
     }
 
-
     configurations {
         // published -- what gets uploaded to the Nexus repository
         published.extendsFrom archives, meta
@@ -292,39 +279,81 @@ subprojects {
             published.extendsFrom signatures
         }
     }
-
-    task uploadPublished {
-
-        doFirst {
-            if (!canDeploy) {
-                throw new InvalidUserDataException("Missing upload credentials. Set '$deployUsernameProperty' and '$deployPasswordProperty' root project properties.")
+    
+    publishing {
+        publications {
+            mavenJava(MavenPublication) {
+                version = parent.version
+                groupId = "org.apache.tapestry"
+                from components.java
+                artifact sourcesJar
+                
+                pom {
+                    name = project.name
+                    // TODO: find some way to get the subproject description here.
+                    // description = 
+                    url = "https://tapestry.apache.org/"
+                    licenses {
+                        license {
+                            name = 'The Apache License, Version 2.0'
+                                    url = 'http://www.apache.org/licenses/LICENSE-2.0.txt'
+                        }
+                    }
+                    scm {
+                        connection = 'scm:git:https://gitbox.apache.org/repos/asf/tapestry-5.git'
+                                developerConnection = 'scm:git://gitbox.apache.org/repos/asf/tapestry-5.git'
+                                url = 'https://git-wip-us.apache.org/repos/asf?p=tapestry-5.git;a=summary'
+                    }
+                }
+                matching {
+                    it.name.endsWith(".jar") || it.name.endsWith(".pom")
+                }
             }
         }
-
         if (canDeploy) {
             repositories {
-                
-                maven {
-                    name = "apacheSnapshots"
-                    url = snapshotUrl
-                    credentials {
-                        username = deployUsername()
-                        password = deployPassword()
+                mavenLocal()
+                if (continuousIntegrationBuild) {
+                    maven {
+                        name = "apacheSnapshots"
+                        url = snapshotUrl
+                        credentials {
+                            username = deployUsername()
+                            password = deployPassword()
+                        }
                     }
                 }
-                
-                maven {
-                    name = "apacheStaging"
-                    url = stagingUrl
-                    credentials {
-                        username = deployUsername()
-                        password = deployPassword()
+                else {
+                    maven {
+                        name = "apacheStaging"
+                        url = stagingUrl
+                        credentials {
+                            username = deployUsername()
+                            password = deployPassword()
+                        }
                     }
                 }
                 
             }
         }
     }
+
+    if (doSign) {
+        apply plugin: "signing"
+        signing {
+            sign publishing.publications.mavenJava
+        }
+    }
+
+    task uploadPublished {
+
+        doFirst {
+            if (!canDeploy) {
+                throw new InvalidUserDataException("Missing upload credentials. Set '$deployUsernameProperty' and '$deployPasswordProperty' root project properties.")
+            }
+        }
+
+    }
 }
 
 subprojects.each { project.evaluationDependsOn(it.name) }
@@ -385,11 +414,12 @@ task aggregateJavadoc(type: Javadoc) {
         addStringOption '-source-path', files(allMainJavaSrcDirs.flatten()).asPath
         addStringOption 'source', '8'
         taglets "org.apache.tapestry5.javadoc.TapestryDocTaglet"
-        exclude "org/apache/tapestry5/internal/plastic/asm/**"
-        exclude "org/apache/tapestry5/internal/webresources/**"
-        exclude "org/apache/tapestry5/webresources/modules/**"
     }
 
+    exclude "org/apache/tapestry5/internal/plastic/asm/**"
+    exclude "org/apache/tapestry5/internal/webresources/**"
+    exclude "org/apache/tapestry5/webresources/modules/**"
+    
     source allMainJavaFiles
 
     classpath += files(allMainSourceSets*.compileClasspath)
@@ -617,7 +647,7 @@ if (canDeploy) {
     }
 
     task generateRelease {
-        dependsOn subprojects.uploadPublished, copyArchives
+        dependsOn subprojects.assemble, subprojects.uploadPublished, subprojects.publish, copyArchives
         group "Release artifact"
         description "Generates and uploads a final release to Apache Nexus and copies archives for deployment"
     }
diff --git a/plastic/LICENSE-ASM-7_0.txt b/plastic/LICENSE-ASM-9_2.txt
similarity index 100%
rename from plastic/LICENSE-ASM-7_0.txt
rename to plastic/LICENSE-ASM-9_2.txt
diff --git a/plastic/build.gradle b/plastic/build.gradle
index 83be57d..ba8ff10 100644
--- a/plastic/build.gradle
+++ b/plastic/build.gradle
@@ -1,5 +1,5 @@
 description = "High-level runtime transformations of Java classes"
-
+project.setProperty("description", "wtf!!!!")
 dependencies {
     implementation "org.slf4j:slf4j-api:${versions.slf4j}"
 }
diff --git a/tapestry-webresources/build.gradle b/tapestry-webresources/build.gradle
index 7121406..32f76f8 100644
--- a/tapestry-webresources/build.gradle
+++ b/tapestry-webresources/build.gradle
@@ -10,6 +10,9 @@ dependencies {
     implementation project(":tapestry-core")
     implementation "com.github.sommeri:less4j:1.12.0"
     implementation "com.google.javascript:closure-compiler-unshaded:v20200504"
+    
+    compileOnly    "com.google.auto.value:auto-value-annotations:1.9"
+    
     implementation "org.mozilla:rhino:1.7.7.2"
 
     testImplementation project(":tapestry-runner")

[tapestry-5] 03/03: TAP5-2703: Quickstart navbar collapse button not working

Posted by th...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

thiagohp pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tapestry-5.git

commit 54622bbe7123f5b399b0a7751816b07b4ae391ef
Author: Thiago H. de Paula Figueiredo <th...@arsmachina.com.br>
AuthorDate: Thu Mar 17 23:38:15 2022 -0300

    TAP5-2703: Quickstart navbar collapse button not working
---
 quickstart/build.gradle                                    |  4 ++--
 .../main/resources/META-INF/maven/archetype-metadata.xml   |  1 +
 .../src/main/java/components/Layout.java                   |  2 +-
 .../main/resources/META-INF/modules/components/Layout.js   |  3 +++
 .../src/test/java/tapestry/RunWithJetty.java               | 14 ++++++++++++++
 5 files changed, 21 insertions(+), 3 deletions(-)

diff --git a/quickstart/build.gradle b/quickstart/build.gradle
index 9f0174e..07feb5e 100644
--- a/quickstart/build.gradle
+++ b/quickstart/build.gradle
@@ -48,8 +48,8 @@ task processFiltered(type: Copy) {
 
     filter(FixCrLfFilter)
     filter(ReplaceTokens, tokens: [
-        quickstartVersion: version,
-        tapestryVersion: version,
+        quickstartVersion: project.parent.version,
+        tapestryVersion: project.parent.version,
         springBootVersion: '2.5.4',
         junitVersion: '5.8.2',
         jacksonVersion: '2.13.1',
diff --git a/quickstart/src/main/resources/META-INF/maven/archetype-metadata.xml b/quickstart/src/main/resources/META-INF/maven/archetype-metadata.xml
index 952d25a..79c2851 100644
--- a/quickstart/src/main/resources/META-INF/maven/archetype-metadata.xml
+++ b/quickstart/src/main/resources/META-INF/maven/archetype-metadata.xml
@@ -31,6 +31,7 @@
             <directory>src/main/resources</directory>
             <includes>
                 <include>log4j2.yml</include>
+                <include>META-INF/**</include>
             </includes>
         </fileSet>
         <fileSet filtered="true" packaged="true">
diff --git a/quickstart/src/main/resources/archetype-resources/src/main/java/components/Layout.java b/quickstart/src/main/resources/archetype-resources/src/main/java/components/Layout.java
index 2d06642..213d442 100644
--- a/quickstart/src/main/resources/archetype-resources/src/main/java/components/Layout.java
+++ b/quickstart/src/main/resources/archetype-resources/src/main/java/components/Layout.java
@@ -14,7 +14,7 @@ import java.time.LocalDate;
 /**
  * Layout component for pages of application test-project.
  */
-@Import(stylesheet = "context:css/app.css",module = { "bootstrap/collapse", "bootstrap/dropdown"})
+@Import(stylesheet = "context:css/app.css", module = "components/Layout")
 public class Layout {
 
     @Inject
diff --git a/quickstart/src/main/resources/archetype-resources/src/main/resources/META-INF/modules/components/Layout.js b/quickstart/src/main/resources/archetype-resources/src/main/resources/META-INF/modules/components/Layout.js
new file mode 100644
index 0000000..3a4d0d8
--- /dev/null
+++ b/quickstart/src/main/resources/archetype-resources/src/main/resources/META-INF/modules/components/Layout.js
@@ -0,0 +1,3 @@
+define(["jquery", "bootstrap/dropdown"], function($) {
+	$('.navbar-toggler').dropdown();
+});
\ No newline at end of file
diff --git a/quickstart/src/main/resources/archetype-resources/src/test/java/tapestry/RunWithJetty.java b/quickstart/src/main/resources/archetype-resources/src/test/java/tapestry/RunWithJetty.java
new file mode 100644
index 0000000..2e2b5e5
--- /dev/null
+++ b/quickstart/src/main/resources/archetype-resources/src/test/java/tapestry/RunWithJetty.java
@@ -0,0 +1,14 @@
+package ${package}.tapestry;
+
+import org.apache.tapestry5.test.JettyRunner;
+
+/**
+ * Runs this webapp using Jetty in the 8080 port.
+ */
+public class RunWithJetty {
+    
+    public static void main(String[] args) throws Exception {
+        new JettyRunner("src/main/webapp", "/", 8080, 8443);
+    }
+
+}