Skip to content
Browse files

damn it, got args around the wrong way, worked on osx, not on linux, …

…put them around the right way and using display to show time since last sync so you can see in the output
  • Loading branch information...
1 parent 4724e8a commit 66114541dcf62978e568663d167b58287a08d28d @ryan-allen committed Apr 22, 2010
Showing with 3 additions and 1 deletion.
  1. +3 −1 sir-sync-a-lot
View
4 sir-sync-a-lot
@@ -146,6 +146,8 @@ private
if last_sync_recorded? # what happens when last sync
display("Performing time based comparison...")
+ seconds = seconds_since_last_sync
+ display("Looking for files changed in the last #{seconds} seconds...")
files_modified_since(seconds_since_last_sync)
else
display("Performing (potentially expensive) checksum comparison...")
@@ -169,7 +171,7 @@ private
end
def seconds_since_last_sync(config = read_config())
- (config[:last_sync_at] - Time.now).ceil
+ (Time.now - config[:last_sync_at]).ceil
end
def files_modified_since(seconds)

0 comments on commit 6611454

Please sign in to comment.
Something went wrong with that request. Please try again.