Search code examples
cocoapodspodfile

Pod install error within terminal


Pod File this error [!] Invalid Podfile file: undefined method `Pod' for # Did you mean? pod. is occuring when I am trying to pod install. In my pod file i have just added 'SwiftKeychainWrapper'

This is a terminal error with cocoapods, also an error with the import the way i imported was

import SwiftKeychainWrapper

[!] Invalid Podfile file: undefined method `Pod' for # Did you mean? pod.

#
# ------------------------------------------- # pod 'Firebase/Database'

Pod 'SwiftKeychainWrapper' #
# -------------------------------------------


Solution

  • just remove capital P, pod must be write with p not with P. Try this pod 'SwiftKeychainWrapper'

    ps.

    If you read carefully the error

    [!] Invalid Podfile file: undefined method `Pod' for # Did you mean? pod.

    it says that Pod does not exist. Did you mean pod