Sha256: 8a605eaa393d49690795e1ff4a0708fbf9c0316943b46c3c8212e104c38a5802

Contents?: true

Size: 872 Bytes

Versions: 1

Compression:

Stored size: 872 Bytes

Contents

require 'pathname'

module Pod
    class Podfile
        module DSL

            def local_pod(name, *requirements)
                basePath = Pathname.new "./"

                path = nil
                basePath.find do |p|
                    if p.basename.to_s == "#{name}.podspec"
                        path = p
                        break
                    end
                end

                if path == nil 
                    raise "\ncannot find local pod: #{name}"
                    return 
                end
                options = requirements.last
                if options and options.kind_of? Hash
                    options[:path] = path.to_s
                    pod(name, *requirements)
                else 
                    pod(name, *requirements, :path => path.to_s)
                end
            end

        end
    end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
cocoapods-developing-folder-0.5 lib/cocoapods-developing-folder/local_pod_DSL.rb