You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Michael Osipov (JIRA)" <ji...@codehaus.org> on 2011/02/07 15:10:22 UTC

[jira] Created: (MASSEMBLY-546) Cannot supply escapeString for filtering

Cannot supply escapeString for filtering
----------------------------------------

                 Key: MASSEMBLY-546
                 URL: http://jira.codehaus.org/browse/MASSEMBLY-546
             Project: Maven 2.x Assembly Plugin
          Issue Type: Improvement
    Affects Versions: 2.2-beta-5
            Reporter: Michael Osipov


I have some txt files filtered in my assembly with <filtered>true</true>. I'd like also some properties tom remain as is and escape filtering. There is no option to. In the resources plugin I can set the filter delims + the escape string. Something like this is necessary for this plugin too.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MASSEMBLY-546) Cannot supply escapeString for filtering

Posted by "Dennis Lundberg (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MASSEMBLY-546?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=255502#action_255502 ] 

Dennis Lundberg commented on MASSEMBLY-546:
-------------------------------------------

Sorry, I misunderstood your request.
We need to add a parameter in the Assembly Plugin to be able to configure it.

> Cannot supply escapeString for filtering
> ----------------------------------------
>
>                 Key: MASSEMBLY-546
>                 URL: http://jira.codehaus.org/browse/MASSEMBLY-546
>             Project: Maven 2.x Assembly Plugin
>          Issue Type: Improvement
>    Affects Versions: 2.2-beta-5
>            Reporter: Michael Osipov
>
> I have some txt files filtered in my assembly with <filtered>true</true>. I'd like also some properties tom remain as is and escape filtering. There is no option to. In the resources plugin I can set the filter delims + the escape string. Something like this is necessary for this plugin too.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MASSEMBLY-546) Cannot supply escapeString for filtering

Posted by "Alix Lourme (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MASSEMBLY-546?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=262079#action_262079 ] 

Alix Lourme commented on MASSEMBLY-546:
---------------------------------------

Is it possible not have any escape character (escapeString = _blank_) ?

Because if the plugin is used to valorize some login/password, the default escape (backslashe) is contraignant.

+Exemple+ : 
With a _filter_ containing : 
{code}
my.password1 = @^\u5
my.password2 = simple\password
{code}

And a file _myConfig.xxx_ : 
{code}
The password1 is ${my.password1}
The password2 is ${my.password2}
{code}

The backslashe is interpreted and must be doubled.

In the exemple, we have a 
* Case 1 : IllegalArgumentException: Malformed \uxxxx encoding.
* Case 2 : (without UTF-8 character), the \ disappears ... result is _simplepassword_

Understand the escape mecanism is not easy in key/value definition.


> Cannot supply escapeString for filtering
> ----------------------------------------
>
>                 Key: MASSEMBLY-546
>                 URL: http://jira.codehaus.org/browse/MASSEMBLY-546
>             Project: Maven 2.x Assembly Plugin
>          Issue Type: Improvement
>    Affects Versions: 2.2-beta-5
>            Reporter: Michael Osipov
>
> I have some txt files filtered in my assembly with <filtered>true</true>. I'd like also some properties tom remain as is and escape filtering. There is no option to. In the resources plugin I can set the filter delims + the escape string. Something like this is necessary for this plugin too.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] (MASSEMBLY-546) Cannot supply escapeString for filtering

Posted by "Dennis Lundberg (JIRA)" <ji...@codehaus.org>.
     [ https://jira.codehaus.org/browse/MASSEMBLY-546?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dennis Lundberg closed MASSEMBLY-546.
-------------------------------------

    Resolution: Fixed

Fixed in r1401670.

I added a new parameter called "escapeString" that works in the same way as for Maven Resources Plugin.
                
> Cannot supply escapeString for filtering
> ----------------------------------------
>
>                 Key: MASSEMBLY-546
>                 URL: https://jira.codehaus.org/browse/MASSEMBLY-546
>             Project: Maven 2.x Assembly Plugin
>          Issue Type: Improvement
>          Components: filtering
>    Affects Versions: 2.2-beta-5
>            Reporter: Michael Osipov
>            Assignee: Dennis Lundberg
>             Fix For: 2.4
>
>
> I have some txt files filtered in my assembly with <filtered>true</true>. I'd like also some properties tom remain as is and escape filtering. There is no option to. In the resources plugin I can set the filter delims + the escape string. Something like this is necessary for this plugin too.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] (MASSEMBLY-546) Cannot supply escapeString for filtering

Posted by "Dennis Lundberg (JIRA)" <ji...@codehaus.org>.
     [ https://jira.codehaus.org/browse/MASSEMBLY-546?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dennis Lundberg updated MASSEMBLY-546:
--------------------------------------

    Fix Version/s: 2.4
         Assignee: Dennis Lundberg
    
> Cannot supply escapeString for filtering
> ----------------------------------------
>
>                 Key: MASSEMBLY-546
>                 URL: https://jira.codehaus.org/browse/MASSEMBLY-546
>             Project: Maven 2.x Assembly Plugin
>          Issue Type: Improvement
>    Affects Versions: 2.2-beta-5
>            Reporter: Michael Osipov
>            Assignee: Dennis Lundberg
>             Fix For: 2.4
>
>
> I have some txt files filtered in my assembly with <filtered>true</true>. I'd like also some properties tom remain as is and escape filtering. There is no option to. In the resources plugin I can set the filter delims + the escape string. Something like this is necessary for this plugin too.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MASSEMBLY-546) Cannot supply escapeString for filtering

Posted by "Michael Osipov (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MASSEMBLY-546?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=270257#comment-270257 ] 

Michael Osipov commented on MASSEMBLY-546:
------------------------------------------

I second that. I think we need a shared component for this.

> Cannot supply escapeString for filtering
> ----------------------------------------
>
>                 Key: MASSEMBLY-546
>                 URL: http://jira.codehaus.org/browse/MASSEMBLY-546
>             Project: Maven 2.x Assembly Plugin
>          Issue Type: Improvement
>    Affects Versions: 2.2-beta-5
>            Reporter: Michael Osipov
>
> I have some txt files filtered in my assembly with <filtered>true</true>. I'd like also some properties tom remain as is and escape filtering. There is no option to. In the resources plugin I can set the filter delims + the escape string. Something like this is necessary for this plugin too.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MASSEMBLY-546) Cannot supply escapeString for filtering

Posted by "Stefan Ferstl (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MASSEMBLY-546?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=266194#action_266194 ] 

Stefan Ferstl commented on MASSEMBLY-546:
-----------------------------------------

The same happens when using a properties file for filtering, for example:

*filter.properties*:
{code}
my.property=${user.home}/somedir
{code}

*plugin config*:
{code}
<plugin>
  <artifactId>maven-assembly-plugin</artifactId>
  <configuration>
    <appendAssemblyId>true</appendAssemblyId>
    <descriptors>
      <descriptor>my-descriptor.xml</descriptor>
    </descriptors>
    <filters>
      <filter>${project.build.directory}/assembly/filter.properties</filter>
    </filters>
  </configuration>
  ...
</plugin>
}
{code}

*resource file*:
{code}
test=${my.property}
{code}

The resource file in the assembly results in:
{code}
test=C:\Documents and Settings\.../somedir
{code}

instead of

{code}
test=${user.home}/somedir
{code}

The filter.properties file itself does not get filtered. Only the resource file does. It would be great to have the ability to exclude some variables from filtering.


> Cannot supply escapeString for filtering
> ----------------------------------------
>
>                 Key: MASSEMBLY-546
>                 URL: http://jira.codehaus.org/browse/MASSEMBLY-546
>             Project: Maven 2.x Assembly Plugin
>          Issue Type: Improvement
>    Affects Versions: 2.2-beta-5
>            Reporter: Michael Osipov
>
> I have some txt files filtered in my assembly with <filtered>true</true>. I'd like also some properties tom remain as is and escape filtering. There is no option to. In the resources plugin I can set the filter delims + the escape string. Something like this is necessary for this plugin too.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MASSEMBLY-546) Cannot supply escapeString for filtering

Posted by "Michael Osipov (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MASSEMBLY-546?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=255503#action_255503 ] 

Michael Osipov commented on MASSEMBLY-546:
------------------------------------------

Dennis, I expect something like this: http://maven.apache.org/plugins/maven-resources-plugin/examples/escape-filtering.html + we need delims http://maven.apache.org/plugins/maven-resources-plugin/resources-mojo.html#delimiters

> Cannot supply escapeString for filtering
> ----------------------------------------
>
>                 Key: MASSEMBLY-546
>                 URL: http://jira.codehaus.org/browse/MASSEMBLY-546
>             Project: Maven 2.x Assembly Plugin
>          Issue Type: Improvement
>    Affects Versions: 2.2-beta-5
>            Reporter: Michael Osipov
>
> I have some txt files filtered in my assembly with <filtered>true</true>. I'd like also some properties tom remain as is and escape filtering. There is no option to. In the resources plugin I can set the filter delims + the escape string. Something like this is necessary for this plugin too.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MASSEMBLY-546) Cannot supply escapeString for filtering

Posted by "Dennis Lundberg (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MASSEMBLY-546?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=270403#comment-270403 ] 

Dennis Lundberg commented on MASSEMBLY-546:
-------------------------------------------

We already have one:
http://maven.apache.org/shared/maven-filtering/

> Cannot supply escapeString for filtering
> ----------------------------------------
>
>                 Key: MASSEMBLY-546
>                 URL: http://jira.codehaus.org/browse/MASSEMBLY-546
>             Project: Maven 2.x Assembly Plugin
>          Issue Type: Improvement
>    Affects Versions: 2.2-beta-5
>            Reporter: Michael Osipov
>
> I have some txt files filtered in my assembly with <filtered>true</true>. I'd like also some properties tom remain as is and escape filtering. There is no option to. In the resources plugin I can set the filter delims + the escape string. Something like this is necessary for this plugin too.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MASSEMBLY-546) Cannot supply escapeString for filtering

Posted by "Rubén DM (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MASSEMBLY-546?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=270256#comment-270256 ] 

Rubén DM commented on MASSEMBLY-546:
------------------------------------

I think this is the same issue. If you don't think so, please let me know, and I will open a new one... 
It would be nice to have also this option from resources plugin filtering: http://maven.apache.org/plugins/maven-resources-plugin/resources-mojo.html#escapeWindowsPaths

In fact, since filtering is an important feature for this plugin, why not providing the same options as in the resources plugin?

> Cannot supply escapeString for filtering
> ----------------------------------------
>
>                 Key: MASSEMBLY-546
>                 URL: http://jira.codehaus.org/browse/MASSEMBLY-546
>             Project: Maven 2.x Assembly Plugin
>          Issue Type: Improvement
>    Affects Versions: 2.2-beta-5
>            Reporter: Michael Osipov
>
> I have some txt files filtered in my assembly with <filtered>true</true>. I'd like also some properties tom remain as is and escape filtering. There is no option to. In the resources plugin I can set the filter delims + the escape string. Something like this is necessary for this plugin too.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

[jira] (MASSEMBLY-546) Cannot supply escapeString for filtering

Posted by "Dennis Lundberg (JIRA)" <ji...@codehaus.org>.
     [ https://jira.codehaus.org/browse/MASSEMBLY-546?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dennis Lundberg updated MASSEMBLY-546:
--------------------------------------

    Component/s: filtering
    
> Cannot supply escapeString for filtering
> ----------------------------------------
>
>                 Key: MASSEMBLY-546
>                 URL: https://jira.codehaus.org/browse/MASSEMBLY-546
>             Project: Maven 2.x Assembly Plugin
>          Issue Type: Improvement
>          Components: filtering
>    Affects Versions: 2.2-beta-5
>            Reporter: Michael Osipov
>            Assignee: Dennis Lundberg
>             Fix For: 2.4
>
>
> I have some txt files filtered in my assembly with <filtered>true</true>. I'd like also some properties tom remain as is and escape filtering. There is no option to. In the resources plugin I can set the filter delims + the escape string. Something like this is necessary for this plugin too.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MASSEMBLY-546) Cannot supply escapeString for filtering

Posted by "Dennis Lundberg (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MASSEMBLY-546?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=254934#action_254934 ] 

Dennis Lundberg commented on MASSEMBLY-546:
-------------------------------------------

Please try the 2.2.1-SNAPSHOT, which has gotten an updated version of maven-filtering.

> Cannot supply escapeString for filtering
> ----------------------------------------
>
>                 Key: MASSEMBLY-546
>                 URL: http://jira.codehaus.org/browse/MASSEMBLY-546
>             Project: Maven 2.x Assembly Plugin
>          Issue Type: Improvement
>    Affects Versions: 2.2-beta-5
>            Reporter: Michael Osipov
>
> I have some txt files filtered in my assembly with <filtered>true</true>. I'd like also some properties tom remain as is and escape filtering. There is no option to. In the resources plugin I can set the filter delims + the escape string. Something like this is necessary for this plugin too.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira