Replies: 2 comments 7 replies
-
No particular reason. Just it's "the same".
Probably when dealing with updates you'll get some stuff changed anyway due
to the smart diff algorithm. But it's not a feature but a side effect.
Anything you can improve, do it please 😃
El mar, 11 abr 2023, 9:23, Smidimir ***@***.***> escribió:
… Is there any reason to override file if copier detects that rendered file
is identical? It surprised me, that copier after ensuring that file have
the same content, writes it anyway. I made this change
<cecc0e6>
that skips identical files.
I wanted to make a pull request with this change, but I couldn't setup
tests to check if this change could break anything.
First reason I needed this change, is that some programs (in my case msvc
compiler for c++) rely on file properties (like timestamp) to check if
there were any changes. So after rendering template where 100% of files
have the same content, msvc recompiles the whole project from scratch
because every timestamp of every file was updated.
Second reason is speed. In my case I got about 20% speedup for copying
template with same result (6 min -> 5 min). I have template with a lot of
files.
—
Reply to this email directly, view it on GitHub
<#1092>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAHNXDORWGXH7QIJB4JYAXLXAUIJNANCNFSM6AAAAAAWZ56WWQ>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
5 replies
-
I ran into the exact same problem. But in my case it is not only speed, but the process fails randomly with 30% chance on the network drive. (That is 30% on each file. If I have 10 files, a failure is guaranteed.) This really is a single line of code to change. I guess it wouldn't take more than 10 minutes for the developers to fix and run the tests. But for us, mortals, checking out the code, struggling with the failed tests, it could take hours before we give up. I would be glad if you would consider implementing this change. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Is there any reason to override file if copier detects that rendered file is identical? It surprised me, that copier after ensuring that file have the same content, writes it anyway. I made this change that skips identical files.
I wanted to make a pull request with this change, but I couldn't setup tests to check if this change could break anything.
First reason I needed this change, is that some programs (in my case msvc compiler for c++) rely on file properties (like timestamp) to check if there were any changes. So after rendering template where 100% of files have the same content, msvc recompiles the whole project from scratch because every timestamp of every file was updated.
Second reason is speed. In my case I got about 20% speedup for copying template with same result (6 min -> 5 min). I have template with a lot of files.
Beta Was this translation helpful? Give feedback.
All reactions