[netbeans] branch master updated: Fix the vendor name regex for Composer #6192

2023-07-13 Thread junichi11
This is an automated email from the ASF dual-hosted git repository.

junichi11 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/netbeans.git


The following commit(s) were added to refs/heads/master by this push:
 new cd3bc27f54 Fix the vendor name regex for Composer #6192
 new 595fa2cf4f Merge pull request #6196 from 
junichi11/php-gh-6192-composer-vendor-name
cd3bc27f54 is described below

commit cd3bc27f546e925ac5598d518b605ef5cefea5ce
Author: Junichi Yamamoto 
AuthorDate: Fri Jul 14 11:52:05 2023 +0900

Fix the vendor name regex for Composer #6192

- https://github.com/apache/netbeans/issues/6192
- https://getcomposer.org/doc/04-schema.md#name
- VendorName/PackageName: 
`^[a-z0-9]([_.-]?[a-z0-9]+)*/[a-z0-9](([_.]|-{1,2})?[a-z0-9]+)*$`
---
 .../modules/php/composer/options/ComposerOptionsValidator.java| 3 ++-
 .../php/composer/options/ComposerOptionsValidatorTest.java| 8 ++--
 2 files changed, 8 insertions(+), 3 deletions(-)

diff --git 
a/php/php.composer/src/org/netbeans/modules/php/composer/options/ComposerOptionsValidator.java
 
b/php/php.composer/src/org/netbeans/modules/php/composer/options/ComposerOptionsValidator.java
index 043bffb6ab..ea1b056a3b 100644
--- 
a/php/php.composer/src/org/netbeans/modules/php/composer/options/ComposerOptionsValidator.java
+++ 
b/php/php.composer/src/org/netbeans/modules/php/composer/options/ComposerOptionsValidator.java
@@ -29,7 +29,8 @@ import org.openide.util.NbBundle;
  */
 public final class ComposerOptionsValidator {
 
-private static final Pattern VENDOR_REGEX = 
Pattern.compile("^[a-z0-9-]+$"); // NOI18N
+// GH-6192 : https://getcomposer.org/doc/04-schema.md#name
+private static final Pattern VENDOR_REGEX = 
Pattern.compile("^[a-z0-9]([_.-]?[a-z0-9]+)*$"); // NOI18N
 private static final Pattern EMAIL_REGEX = 
Pattern.compile("^\\w+[\\.\\w\\-]*@\\w+[\\.\\w\\-]*\\.[a-z]{2,}$", 
Pattern.CASE_INSENSITIVE); // NOI18N
 private static final Pattern AUTHOR_NAME_REGEX = 
Pattern.compile("^[^\\d]+$"); // NOI18N
 
diff --git 
a/php/php.composer/test/unit/src/org/netbeans/modules/php/composer/options/ComposerOptionsValidatorTest.java
 
b/php/php.composer/test/unit/src/org/netbeans/modules/php/composer/options/ComposerOptionsValidatorTest.java
index 2643ff739f..8c0260038e 100644
--- 
a/php/php.composer/test/unit/src/org/netbeans/modules/php/composer/options/ComposerOptionsValidatorTest.java
+++ 
b/php/php.composer/test/unit/src/org/netbeans/modules/php/composer/options/ComposerOptionsValidatorTest.java
@@ -52,11 +52,15 @@ public class ComposerOptionsValidatorTest extends 
NbTestCase {
 result = new ComposerOptionsValidator()
 .validateVendor("my.company")
 .getResult();
-assertTrue(result.hasWarnings());
+assertFalse(result.hasWarnings());
 result = new ComposerOptionsValidator()
 .validateVendor("my_company")
 .getResult();
-assertTrue(result.hasWarnings());
+assertFalse(result.hasWarnings());
+result = new ComposerOptionsValidator()
+.validateVendor("my-company")
+.getResult();
+assertFalse(result.hasWarnings());
 }
 
 public void testValidAuthorEmail() {


-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[netbeans] branch master updated: VisualDevelopmentUtil should close its streams.

2023-07-13 Thread mbien
This is an automated email from the ASF dual-hosted git repository.

mbien pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/netbeans.git


The following commit(s) were added to refs/heads/master by this push:
 new ee2eb18a3c VisualDevelopmentUtil should close its streams.
 new 7cb0985514 Merge pull request #6172 from Alfusainey/issue-6165
ee2eb18a3c is described below

commit ee2eb18a3c0f97b4539eb69f390252c6fadb7ba4
Author: Alfusainey Jallow 
AuthorDate: Mon Jul 10 09:12:30 2023 +0200

VisualDevelopmentUtil should close its streams.

Removed unused copy method.

Signed-off-by: Alfusainey Jallow 
---
 .../netbeans/qa/form/VisualDevelopmentUtil.java| 30 +++---
 1 file changed, 4 insertions(+), 26 deletions(-)

diff --git 
a/java/form/test/qa-functional/src/org/netbeans/qa/form/VisualDevelopmentUtil.java
 
b/java/form/test/qa-functional/src/org/netbeans/qa/form/VisualDevelopmentUtil.java
index d272be364b..94881675a9 100644
--- 
a/java/form/test/qa-functional/src/org/netbeans/qa/form/VisualDevelopmentUtil.java
+++ 
b/java/form/test/qa-functional/src/org/netbeans/qa/form/VisualDevelopmentUtil.java
@@ -19,36 +19,14 @@
 
 package org.netbeans.qa.form;
 
-import java.io.*;
+import java.io.IOException;
+import java.nio.file.Files;
+import java.nio.file.Paths;
 
 public class VisualDevelopmentUtil {
 public static String JAVA_VERSION = System.getProperty("java.version");
 
 public static String readFromFile(String filename) throws IOException   {
-File f = new File(filename); 
-int size = (int) f.length();
-int bytes_read = 0;
-FileInputStream in = new FileInputStream(f);
-byte[] data = new byte [size];
-while(bytes_read < size)
-bytes_read += in.read(data, bytes_read, size-bytes_read);
-return new String(data);
+return new String(Files.readAllBytes(Paths.get(filename)));
 }
-
-public static void copy(File src, File dst) throws IOException {
-InputStream in = new FileInputStream(src);
-OutputStream out = new FileOutputStream(dst);
-
-// Transfer bytes from in to out
-byte[] buf = new byte[1024];
-int len;
-while ((len = in.read(buf)) > 0) {
-out.write(buf, 0, len);
-}
-in.close();
-out.close();
-}
-
-
-
 }


-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[netbeans-mavenutils-nbm-maven-plugin] branch dependabot/maven/master/org.codehaus.modello-modello-maven-plugin-2.1.2 deleted (was 943fdbe)

2023-07-13 Thread github-bot
This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a change to branch 
dependabot/maven/master/org.codehaus.modello-modello-maven-plugin-2.1.2
in repository 
https://gitbox.apache.org/repos/asf/netbeans-mavenutils-nbm-maven-plugin.git


 was 943fdbe  Bump modello-maven-plugin from 2.1.1 to 2.1.2

The revisions that were on this branch are still contained in
other references; therefore, this change does not discard any commits
from the repository.


-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[netbeans-mavenutils-nbm-maven-plugin] branch master updated (b5a8a47 -> 3b0b4d3)

2023-07-13 Thread skygo
This is an automated email from the ASF dual-hosted git repository.

skygo pushed a change to branch master
in repository 
https://gitbox.apache.org/repos/asf/netbeans-mavenutils-nbm-maven-plugin.git


from b5a8a47  Merge pull request #99 from ebarboni/rat
 add 943fdbe  Bump modello-maven-plugin from 2.1.1 to 2.1.2
 new 3b0b4d3  Merge pull request #100 from 
apache/dependabot/maven/master/org.codehaus.modello-modello-maven-plugin-2.1.2

The 1 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:
 nbm-maven-plugin/pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[netbeans-mavenutils-nbm-maven-plugin] 01/01: Merge pull request #100 from apache/dependabot/maven/master/org.codehaus.modello-modello-maven-plugin-2.1.2

2023-07-13 Thread skygo
This is an automated email from the ASF dual-hosted git repository.

skygo pushed a commit to branch master
in repository 
https://gitbox.apache.org/repos/asf/netbeans-mavenutils-nbm-maven-plugin.git

commit 3b0b4d3cdc6c1f169e956006bee298d3b461fda5
Merge: b5a8a47 943fdbe
Author: Eric Barboni 
AuthorDate: Thu Jul 13 13:41:42 2023 +0200

Merge pull request #100 from 
apache/dependabot/maven/master/org.codehaus.modello-modello-maven-plugin-2.1.2

Bump modello-maven-plugin from 2.1.1 to 2.1.2

 nbm-maven-plugin/pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)



-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[netbeans-mavenutils-nbm-maven-plugin] branch master updated: remove obsolete taglet + rat fix

2023-07-13 Thread skygo
This is an automated email from the ASF dual-hosted git repository.

skygo pushed a commit to branch master
in repository 
https://gitbox.apache.org/repos/asf/netbeans-mavenutils-nbm-maven-plugin.git


The following commit(s) were added to refs/heads/master by this push:
 new 04e8326  remove obsolete taglet + rat fix
 new b5a8a47  Merge pull request #99 from ebarboni/rat
04e8326 is described below

commit 04e8326df7ffa6329a077c45446a9ec1b2d7ac58
Author: Eric Barboni 
AuthorDate: Fri Jun 2 11:59:30 2023 +0200

remove obsolete taglet + rat fix
---
 nb-repository-plugin/pom.xml | 13 +
 nb-shared/pom.xml| 11 ---
 nbm-maven-plugin/pom.xml | 39 +--
 3 files changed, 14 insertions(+), 49 deletions(-)

diff --git a/nb-repository-plugin/pom.xml b/nb-repository-plugin/pom.xml
index 9139d1b..f7e3092 100644
--- a/nb-repository-plugin/pom.xml
+++ b/nb-repository-plugin/pom.xml
@@ -251,18 +251,7 @@ under the License.
 
http://maven.apache.org/ref/${maven.version}/maven-plugin-api/apidocs/
 
https://maven.apache.org/shared/maven-reporting-api/apidocs/
 
http://maven.apache.org/ref/${maven.version}/maven-settings/apidocs/
-
-
-
-org.apache.maven.plugin-tools
-maven-plugin-tools-javadoc
-
-
-org.codehaus.plexus
-plexus-component-javadoc
-1.6
-
-
+
 
 
 
diff --git a/nb-shared/pom.xml b/nb-shared/pom.xml
index 416a9b4..250d376 100644
--- a/nb-shared/pom.xml
+++ b/nb-shared/pom.xml
@@ -154,17 +154,6 @@ under the License.
 
https://maven.apache.org/shared/maven-reporting-api/apidocs/
 
http://maven.apache.org/ref/${maven.version}/maven-settings/apidocs/
 
-
-
-org.apache.maven.plugin-tools
-maven-plugin-tools-javadoc
-
-
-org.codehaus.plexus
-plexus-component-javadoc
-1.5.5
-
-
 
 
 
diff --git a/nbm-maven-plugin/pom.xml b/nbm-maven-plugin/pom.xml
index 2243b3b..4b9e0bb 100644
--- a/nbm-maven-plugin/pom.xml
+++ b/nbm-maven-plugin/pom.xml
@@ -294,6 +294,17 @@ under the License.
 
 
 
+
+org.apache.rat
+apache-rat-plugin
+
+
+
+**/*.mf
+**/*.MF
+
+
+
 
 
 
@@ -342,19 +353,7 @@ under the License.
 
 
 
https://maven.apache.org/ref/${maven.version}/maven-settings/apidocs/
-
-
-
-org.apache.maven.plugin-tools
-maven-plugin-tools-javadoc
-3.4
-
-
-org.codehaus.plexus
-plexus-component-javadoc
-1.6
-
-
+
 
 
 
@@ -388,17 +387,7 @@ under the License.
 org.codehaus.mojo
 taglist-maven-plugin
 3.0.0
-
-
-org.apache.rat
-apache-rat-plugin
-
-
-**/*.mf
-**/*.MF
-
-
-
+  
 
 
 
@@ -448,7 +437,6 @@ under the License.
 
 run-its
 
-
 
 
 maven-invoker-plugin
@@ -483,7 +471,6 @@ under the License.
 
 
 
-
 
 
 


-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists