def install_assemblers(which='all', dir='~/.local')

      dir = File.expand_path dir
      unless File.exist? dir
        FileUtils.mkdir_p dir
      end

      assembler_deps = {}
      Biopsy::Settings.instance.target_dir.each do |dir|
        Dir.chdir dir do
          Dir['*.yml'].each do |file|
            dephash = YAML.load_file file
            assembler_deps[dephash['name']] = dephash['bindeps']
            assembler_deps[dephash['shortname']] = dephash['bindeps']
          end
        end
      end

      assemblers = [which]
      if which == 'all'
        assemblers = assembler_deps.keys
      end

      to_install = assembler_deps.keys.select do |a|
        assemblers.include?(a)
      end

      if to_install.empty?
        logger.error "Tried to install #{which}, but it wasn't available"
        exit(1)
      end

      to_install.each do |assembler|
        bindeps = assembler_deps[assembler]
        unpack = bindeps.key?('unpack') ? bindeps['unpack'] : true;
        libraries = bindeps.key?('libraries') ? bindeps['libraries'] : []
        dep = Bindeps::Dependency.new(assembler,
          bindeps['binaries'],
          bindeps['version'],
          bindeps['url'],
          unpack,
          libraries)
        dep.install_missing dir
      end

    end
def install_assemblers(which='all', dir='~/.local')

      dir = File.expand_path dir
      unless File.exist? dir
        FileUtils.mkdir_p dir
      end

      assembler_deps = {}
      Biopsy::Settings.instance.target_dir.each do |dir|
        Dir.chdir dir do
          Dir['*.yml'].each do |file|
            dephash = YAML.load_file file
            assembler_deps[dephash['name']] = dephash['bindeps']
            assembler_deps[dephash['shortname']] = dephash['bindeps']
          end
        end
      end

      assemblers = [which]
      if which == 'all'
        assemblers = assembler_deps.keys
      end

      to_install = assembler_deps.keys.select do |a|
        assemblers.include?(a)
      end

      if to_install.empty?
        logger.error "Tried to install #{which}, but it wasn't available"
        exit(1)
      end

      to_install.each do |assembler|
        bindeps = assembler_deps[assembler]
        unpack = bindeps.key?('unpack') ? bindeps['unpack'] : true;
        libraries = bindeps.key?('libraries') ? bindeps['libraries'] : []
        dep = Bindeps::Dependency.new(assembler,
          bindeps['binaries'],
          bindeps['version'],
          bindeps['url'],
          unpack,
          libraries)
        dep.install_missing dir
      end

    end
list_assemblers