This repository has been archived by the owner on Oct 27, 2020. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 51
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
It's not always reliable to use `mtime`, so allowing for a `compare` function to be passed makes it possible for custom logic to be used. (ie. hashing)
alexander-akait
previously approved these changes
May 30, 2019
Codecov Report
@@ Coverage Diff @@
## master #79 +/- ##
===========================================
+ Coverage 57.81% 79.23% +21.41%
===========================================
Files 2 2
Lines 128 130 +2
Branches 20 20
===========================================
+ Hits 74 103 +29
+ Misses 46 27 -19
+ Partials 8 0 -8
Continue to review full report at Codecov.
|
alexander-akait
approved these changes
May 30, 2019
The custom compare is not very useful, when we need to compare the hash of the file, the callback parameter of compare is not competent. |
This pr feels more appropriate |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is a recreation of #71 where I preserved the original commits and added a test case, the only one I think it is worth it to have.
It's not always reliable to use
mtime
, so allowing for acompare
function to be passed makes it possible for custom logic to be used. (ie. hashing)This PR contains a:
Motivation / Use-Case
In our CI environment, the
mtime
doesn't always match when it probably should, so we'd like to use something else (like file hashing). This is a simple update to expose acompare
option that can be used to provide custom logic.It's been mentioned before (#34 #41 #29)
Breaking Changes
No breaking changes
/CC @evilebottnawi