Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Don' show any output when file not changed.

  • Loading branch information...
commit f366981ac847973137dbd1d4f9cf7b3480f9e3e9 1 parent e8aaa40
@miloops authored
Showing with 3 additions and 5 deletions.
  1. +3 −5 lib/jammit/s3_uploader.rb
View
8 lib/jammit/s3_uploader.rb
@@ -71,7 +71,7 @@ def upload_from_glob(glob)
use_gzip = true
remote_path = remote_path.gsub(/\.gz$/, "")
end
-
+
# check if the file already exists on s3
begin
obj = @bucket.objects.find_first(remote_path)
@@ -79,7 +79,7 @@ def upload_from_glob(glob)
obj = nil
end
- # if the object does not exist, or if the MD5 Hash / etag of the
+ # if the object does not exist, or if the MD5 Hash / etag of the
# file has changed, upload it
if !obj || (obj.etag != Digest::MD5.hexdigest(File.read(local_path)))
@@ -97,8 +97,6 @@ def upload_from_glob(glob)
log "File changed and will be invalidated in cloudfront: #{remote_path}"
@changed_files << remote_path
end
- else
- log "file has not changed: #{remote_path}"
end
end
end
@@ -118,7 +116,7 @@ def find_or_create_bucket
bucket
end
end
-
+
def invalidate_cache(files)
paths = ""
files.each do |key|
Please sign in to comment.
Something went wrong with that request. Please try again.