Top Level Namespace
Defined Under Namespace
Modules: CocoaPodsGiteeRepo, Pod
Constant Summary collapse
- UTIL =
Pod::GiteeRepo::GiteeRepoUtil
Instance Method Summary collapse
-
#create_source_from_name(source_name) ⇒ GiteeRepoSource
Source of the local spec repo which corresponds to to the given name.
Instance Method Details
#create_source_from_name(source_name) ⇒ GiteeRepoSource
Returns source of the local spec repo which corresponds to to the given name.
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 |
# File 'lib/cocoapods_plugin.rb', line 21 def create_source_from_name(source_name) art_repo = "#{UTIL.get_gitee_repos_dir}/#{source_name}" repos_dir = Pod::Config.instance.repos_dir repo = repos_dir + source_name Pod::UI.puts "#{art_repo}/.artpodrc\n" if File.exist?("#{art_repo}/.artpodrc") url = File.read("#{art_repo}/.artpodrc") Pod::GiteeRepoSource.new(art_repo, url) elsif Dir.exist?("#{repo}") Pod::GiteeRepoSource.new(repo, ''); else raise Pod::Informative.exception "repo #{source_name} does not exist." end end |