Skip to content

Instantly share code, notes, and snippets.

@amiracam
Created October 22, 2013 17:23
Show Gist options
  • Save amiracam/7104614 to your computer and use it in GitHub Desktop.
Save amiracam/7104614 to your computer and use it in GitHub Desktop.
test for directory scanning issues in CentOS 6.3 final , using JRuby
require 'listen'
Listen.to('./listener',force_polling: true) do |modified, added, removed|
puts "modified absolute path: #{modified}"
puts "added absolute path: #{added}"
puts "removed absolute path: #{removed}"
end
sleep 2
File.open('./listener/test.txt', 'w') do |f|
f.puts "does this work or not ?"
end
sleep 2
puts "Exiting test"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment