0

I'm having the same problem as this question . His problem is almost identical to mine. In fact, we're following the same tutorial. However, the answer that solved his problem didn't work for me. I opened up my project via .xcodeworkspace and I'm still getting the error "No such module 'SwiftyDropbox'".

Here's the code for the AppDelegate.swift

enter image description here

The info.plist

enter image description here

And the Pods

enter image description here enter image description here

The Podfile

enter image description here

Community
  • 1
  • 1
Theodore.K
  • 384
  • 2
  • 7
  • 21
  • 1
    Can you provide more info, like the code of your pod file, and in which file you are trying to import the module – Pang Ho Ming Dec 23 '16 at 02:24
  • @PangHoMing I just added stuff. Let me know if more is needed. Thank you! – Theodore.K Dec 23 '16 at 02:33
  • So, can you see SwiftyDropbox in the Project Navigator section? (the navigation view on the left hand side) – Pang Ho Ming Dec 23 '16 at 02:41
  • You should have a file in there called `Podfile`. Here's a tutorial that should set you on the right path re: Cocoapod installation. I think that's where your problem lives. https://www.raywenderlich.com/97014/use-cocoapods-with-swift – Adrian Dec 23 '16 at 02:54
  • @Theodore.K and if you dont mind... you just create a github repo for this question, so we can read you code, pull down your project and fix it. (Cocoapods is troublesome sometime :p ) – Pang Ho Ming Dec 23 '16 at 02:57
  • @Adrian I do have the Podfile. Check the new screenshot in my question. – Theodore.K Dec 23 '16 at 20:01
  • @PangHoMing I didn't know that's what GitHub was for/don't use it. I'l definitely do that, and will send you a link. Thank you so much! – Theodore.K Dec 23 '16 at 20:01
  • @PangHoMing I don't know if I did it right, but my example project is zipped up and available on GitHub at this address https://github.com/traviskaenel/GaethrExample – Theodore.K Dec 23 '16 at 20:09
  • not doing it right. but i can still download it :D – Pang Ho Ming Dec 23 '16 at 20:10
  • 1
    hey did you add the line " pod 'SwiftyDropbox' " to your Podfile? cant find it – Pang Ho Ming Dec 23 '16 at 20:12
  • What @PangHoMing said. Also, it's best to post text, not screen caps with questions. Much easier to read. Easier to read -> faster answers. The steps to install a cocoa pod are listed in the link I posted above. – Adrian Dec 23 '16 at 20:19

1 Answers1

2

You need to install CocoaPods on your computer, if you haven't done so already. Here's what I'd do, based on this Ray Wenderlich Tutorial on Cocoapods.

==Begin One Time Setup Stuff==

Step 1, from Terminal (only if you haven't done so already): Check if you've got cocoapods installed: pod --version

If you've got it installed, proceed to Step 3. Otherwise, install CocoaPods as follows:

sudo gem install cocoapods

Step 2, from Terminal: pod setup --verbose

==End One Time Setup Stuff==

Step 3, from Terminal: cd ~/Path/To/Folder/Containing/YourProject then... pod init

Step 4, from Terminal: open -a Xcode Podfile

Step 5, from Xcode:

Add in a line for your CocoaPod underneath # Pods for GaethrExample:

pod 'SwiftyDropbox'

Step 6, from Xcode:

Close Xcode

Step 7, from Terminal in the directory your project is located in. If you're unsure, type pwd and it will give you the working directory you're in.

pod install

Nuke derived data and re-open your project as a WORKSPACE!. Clean caches and rebuild. You've just installed your first CocoaPod.

Adrian
  • 16,233
  • 18
  • 112
  • 180