Sha256: dacf9b7e9a6dc8a08438219e3f37c9f12c9af2ee7bc93556570ebf5c9213ea4e

Contents?: true

Size: 1.22 KB

Versions: 1

Compression:

Stored size: 1.22 KB

Contents

require_relative "teuton-get/repo/local_info"
require_relative "teuton-get/repo/local_repo"
require_relative "teuton-get/repo/repo_config"
require_relative "teuton-get/repo/repo_data"
require_relative "teuton-get/searcher"
require_relative "teuton-get/downloader"
require "debug"

module TeutonGet
  # Create metadata for local user teuton test
  def self.create_info(testpath)
    LocalInfo.new.user_create(testpath)
  end

  # Create metadata for local user teuton repository
  def self.create_repo(dirpath)
    LocalRepo.new_by_default.create(dirpath)
  end

  # Download remote teuton test
  def self.download(test_id, options)
    Downloader.new.run(test_id)
  end

  # Create Teuton Repo config file
  def self.init
    RepoConfig.new_by_default.create
    refresh # Auto repo refresh
  end

  # Refresh Teuton Repo Data
  def self.refresh
    RepoData.new_by_default.refresh
  end

  def self.show_repo_list
    RepoConfig.new_by_default.show_list
  end

  def self.show_info(test_id)
    repo_data = RepoData.new_by_default
    info = repo_data.get(test_id)
    repo_data.show_testinfo(info) unless info == {}
  end

  def self.search(filter)
    searcher = Searcher.new_by_default
    searcher.get(filter)
    searcher.show_result
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
teuton-get-0.2.6 lib/teuton-get.rb