diff --git a/lib/noprocast.rb b/lib/noprocast.rb index 16ac85f..9345182 100644 --- a/lib/noprocast.rb +++ b/lib/noprocast.rb @@ -25,6 +25,7 @@ class Noprocast File.open("/etc/hosts", 'a') do |file| file << "\n\n# noprocast start\n#{current_hosts.map { |host| "127.0.0.1 #{host}" }.join("\n")}\n# noprocast end" end + system "dscacheutil -flushcache" # only for OSX >= 10.5: flush the DNS cache end def deactivate! @@ -57,6 +58,7 @@ class Noprocast end def edit! + setup_deny_file_if_required! editor = ENV['EDITOR'] || 'vi' system "#{editor} #{deny_file_path}" end diff --git a/noprocast.gemspec b/noprocast.gemspec index 2a7aa86..6588e8d 100644 --- a/noprocast.gemspec +++ b/noprocast.gemspec @@ -5,7 +5,7 @@ Gem::Specification.new do |s| s.name = %q{noprocast} - s.version = "0.1.2" + s.version = "0.1.3" s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version= s.authors = ["Rob Watson"]