Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

touch in slices of 100 instead of 1000, to prevent "Argument list too…

… long"
  • Loading branch information...
commit 7fb3e16b0504201c7c2d3d807c2a227372086e05 1 parent fed6873
Eivind Hagen authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  lib/turbo-sprockets/tasks/assets.rake
View
2  lib/turbo-sprockets/tasks/assets.rake
@@ -76,7 +76,7 @@ namespace :assets do
if digest.nil?
::Rails.logger.debug "Updating mtimes for current assets..."
paths = known_assets.map { |asset| File.join(target, asset) }
- paths.each_slice(1000) do |slice|
+ paths.each_slice(100) do |slice|
# File.utime raises 'Operation not permitted' unless user is owner of file.
# Non-owners have permission to update mtime to the current time using 'touch'.
`touch -c #{slice.shelljoin}`

1 comment on commit 7fb3e16

@ahoward

yuk. why not simply

  FileUtils.touch(paths.select{|path| test(?e, path)})
Please sign in to comment.
Something went wrong with that request. Please try again.