anchor.diff:  
     Find.find("/home/#{uname}/uploads") do |path|
       case path
  -    when /.*\.csv$/
  +    when /.*\.csv$/i
         process(org_slug, path, "CSV")
  -    when /.*\.gz$/
  +    when /.*\.gz$/i
         process(org_slug, path, "GZIP")
  -    when /.*\.zip$/
  +    when /.*\.zip$/i
         process(org_slug, path, "ZIP")
       end
     end
  
positive.code: require 'net/http'
  require 'uri'
  require 'json'
  
  def get_dna org_slug, key
    uri = URI.parse(URI.encode("https://api.evertrue.com/1.0/#{org_slug}/dna/#{key}"))
    http = Net::HTTP.new(uri.host, uri.port)
    http.use_ssl = true
  
negative.code:   body["response"]["data"]
  end
  
  def send_to_new_importer(org_slug, path, compression, is_full_import)
  end
  
  def send_to_legacy_importer(org_slug, path, compression, is_full_import)
  end
  
  def compress_if_not_already(path, compression)
    if compression != "CSV"
      return path
    end
  
    Zlib::GzipWriter.open("#{path}.gz", Zlib::BEST_COMPRESSION) do |gz|
      gz.mtime = File.mtime(path)
      gz.orig_name = File.basename(path)
      gz.write(File.binread(path))
    end
  
    FileUtils.rm(path)
    "#{path}.gz"
  end
  
  def process(org_slug, path, compression)
    # check file is open
  
    is_full_import = (File.basename(path) =~ /\.full\./i)
  
    to_new_importer = !get_dna(org_slug, "ET.Routing.Upload.Importer2").to_i.zero?
  
    if to_new_importer
      send_to_new_importer(org_slug, path, compression, is_full_import)
    else
      send_to_legacy_importer(org_slug, path, compression, is_full_import)
    end
  
    compressed_path = compress_if_not_already(path, compression)
  
    FileUtils.chmod(0700, compressed_path)
    FileUtils.chown('root', 'root', compressed_path)
    FileUtils.mv(compressed_path, '/var/evertrue/uploads')
  end
  
  unames = [<% Array(@unames).each do |uname| %>"<%= uname %>", <% end -%>]
  