[Commented] (MASSEMBLY-856) Ability to overwrite existing files

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Commented] (MASSEMBLY-856) Ability to overwrite existing files

JIRA jira@apache.org

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

Guillaume Boué commented on MASSEMBLY-856:
------------------------------------------

You can already exclude the {{conf.properties}} file from the first file set, without the need to overwrite:

{code:xml}
<fileSet>
  <directory>dir1</directory>
  <outputDirectory>release</outputDirectory>
  <excludes>
    <exclude>conf.properties</exclude>
  </excludes>
</fileSet>
{code}

> Ability to overwrite existing files
> -----------------------------------
>
>                 Key: MASSEMBLY-856
>                 URL: https://issues.apache.org/jira/browse/MASSEMBLY-856
>             Project: Maven Assembly Plugin
>          Issue Type: Improvement
>    Affects Versions: 2.2-beta-5, 2.5.4, 3.0.0
>            Reporter: Kamal Mettananda
>              Labels: features
>
> This is a request to add <overwrite/> element to <fileSet> in assembly file.
> Currently, it is not possible to overwrite the already existing files inside the expected archive with new files.
> e.g.:
> Expectation of below assembly file is to have the conf.properties file in dir2 after the zip file is generated.
> {code:xml}
> <assembly>
>     <id>dist</id>
>     <formats>
>         <format>zip</format>
>     </formats>
>     <includeBaseDirectory>false</includeBaseDirectory>
>     <fileSets>
>         <!-- copy a directory named dir1 having a conf.properties files -->
>         <fileSet>
>             <directory>dir1</directory>
>             <outputDirectory>release</outputDirectory>
>         </fileSet>
>         <!-- copy another directory named dir2 having a conf.properties files -->
>         <fileSet>
>             <directory>dir2</directory>
>             <outputDirectory>release</outputDirectory>
>             <overwrite>true</overwrite>
>         </fileSet>
>     </fileSets>
> </assembly>
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)
Loading...