[ 
https://issues.apache.org/jira/browse/MASSEMBLY-791?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17740981#comment-17740981
 ] 

ASF GitHub Bot commented on MASSEMBLY-791:
------------------------------------------

elharo commented on code in PR #148:
URL: 
https://github.com/apache/maven-assembly-plugin/pull/148#discussion_r1255699674


##########
src/main/java/org/apache/maven/plugins/assembly/AssemblerConfigurationSource.java:
##########
@@ -223,4 +223,12 @@ public interface AssemblerConfigurationSource {
      * @return Override group name.
      */
     String getOverrideGroupName();
+
+    /**
+     * @return mask which is applied to permissions of files/directories 
before they are put into assembly.
+     * If {@code null} then the mask is not explicitly configured and remains 
implementation-specific.

Review Comment:
   Is it really implementation specific? Not just that there simply isn't a 
mask? How many implementations are there?



##########
src/main/java/org/apache/maven/plugins/assembly/mojos/AbstractAssemblyMojo.java:
##########
@@ -430,6 +430,15 @@ public abstract class AbstractAssemblyMojo extends 
AbstractMojo implements Assem
     @Parameter
     private String overrideGroupName;
 
+    /**
+     * Override of mask which is applied to permissions of files/directories 
before they are put into assembly.
+     * If {@code null} then the mask is not explicitly configured and remains 
implementation-specific.
+     * If invalid value is specified - like negative value - then behaviour is 
implementation specific, i.e. depends

Review Comment:
   an invalid value
   such as a negative value
   the behavior
   That is, it depends on the underlying
   of assembly --> the assembly



##########
src/main/java/org/apache/maven/plugins/assembly/mojos/AbstractAssemblyMojo.java:
##########
@@ -430,6 +430,15 @@ public abstract class AbstractAssemblyMojo extends 
AbstractMojo implements Assem
     @Parameter
     private String overrideGroupName;
 
+    /**
+     * Override of mask which is applied to permissions of files/directories 
before they are put into assembly.
+     * If {@code null} then the mask is not explicitly configured and remains 
implementation-specific.
+     * If invalid value is specified - like negative value - then behaviour is 
implementation specific, i.e. depends
+     * on underlying library which is used for building of assembly.
+     */
+    @Parameter
+    private Integer overrideUmask;

Review Comment:
   Does this actually override a umask or does it set a umask? In the other 
cases above — GID, username — these are set on the files and may vary from one 
file to the next.  umask, however, is not a per-file property. It's applied to 
the permissions of the file (which is a per-file property)



##########
src/it/projects/bugs/massembly-791/pom.xml:
##########
@@ -0,0 +1,64 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0";
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/xsd/maven-4.0.0.xsd";>
+  <modelVersion>4.0.0</modelVersion>
+  <parent>
+    <groupId>org.apache.maven.plugin.assembly.test</groupId>
+    <artifactId>it-project-parent</artifactId>
+    <version>1</version>
+  </parent>
+
+  <groupId>org.apache.maven.its</groupId>
+  <artifactId>massembly-791</artifactId>
+  <packaging>pom</packaging>
+  <version>1.0</version>
+
+  <properties>
+    
<project.build.outputTimestamp>2023-06-07T10:18:31Z</project.build.outputTimestamp>

Review Comment:
   Additional public API is too heavyweight a solution to work is too 
heavyweight a solution for a bug that can be fixed at the source.



##########
src/main/java/org/apache/maven/plugins/assembly/AssemblerConfigurationSource.java:
##########
@@ -223,4 +223,12 @@ public interface AssemblerConfigurationSource {
      * @return Override group name.
      */
     String getOverrideGroupName();
+
+    /**
+     * @return mask which is applied to permissions of files/directories 
before they are put into assembly.

Review Comment:
   the assembly





> fileMode not set in dependencySet creating format tar.gz
> --------------------------------------------------------
>
>                 Key: MASSEMBLY-791
>                 URL: https://issues.apache.org/jira/browse/MASSEMBLY-791
>             Project: Maven Assembly Plugin
>          Issue Type: Bug
>          Components: permissions
>    Affects Versions: 2.6
>         Environment: Linux and Windows
>            Reporter: Rick Poleshuck
>            Priority: Major
>
> The fileMode is ignored within a dependencySet while creating a tar.gz 
> archive. This works just fine in 2.4.
>     <dependencySets>
>         <dependencySet>
>             <includes>
>                 <include>com.company:dependency-artifact</include>
>             </includes>
>             <unpack>true</unpack>
>             <unpackOptions>
>                 <includes>
>                     <include>*.py</include>
>                 </includes>
>             </unpackOptions>
>             <outputDirectory/>
>             <fileMode>0750</fileMode>
>             <directoryMode>0750</directoryMode>
>         </dependencySet>
>     </dependencySets>
> </ 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to