New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature] Append/Merge Files #154
Comments
Could you keep an eye on #103 which proposes a |
I'd love to see this feature. @michael-ciniawsky Is this dependent on #103? Or can this proceed regardless? It looks like such a simple change... |
@markwoon Nope it doesn't, feel always free to open a PR |
@kpalatzky Can you submit a PR, or would you be OK with me creating a PR based on your changes? |
@markwoon PR welcome |
@markwoon It would be great if you can create the PR, because i have currently no time for it. If you dont want do it, i can do it within the next weeks. |
Is anybody actively working on this? I've found I have a need for this feature as well. If not, I am happy to construct and submit the PR. I've tried @kpalatzky's fork, and I could bring in that logic and write some tests. I can do it tomorrow. |
This plugins intent isn't to merge file contents, it copies files from point A to point B & loaders & plugins for the most part should do one thing. If someone wants to create a plugin, technically another one as there are already a few feel free. If someone want to create one within contrib, feel free to contact me. In either case, extending the API to handle merging / appending / stitching / truncating of file contents is functionality that is outside the scope of this plugin. |
@d3viant0ne I think that if you often have the same from path you need more than one way to deal with it. In our case we have multible plugins with the same file ( And we are building one project out of these plugins: In this case you can copy the Therefore, the only reasonable reason is to add additional parameters is to this plugin. |
This would be a great feature! |
Now you can do it using the |
Currently, there is only one option to overwrite the contents of a file, but none to merge the contents. Here it would make sense to offer a
append
option. If this is set totrue
, the files should be merged.Here is an example of the expected result:
The result should be following (
./dist/phrases.txt
):This feature has already been implemented by myself. You can find it in this fork:
https://github.com/kpalatzky/copy-webpack-plugin
If you are interested, you can do it yourself or I will prepare a pull request for you.
The text was updated successfully, but these errors were encountered: