1
00:00:07,460 --> 00:00:13,000
Hey buddy what's going on this is Caleb with Debb slopes dot com and in this video we're going to go

2
00:00:13,000 --> 00:00:16,570
ahead and install the cocoa pods we need for this project.

3
00:00:16,570 --> 00:00:22,150
So go ahead and pull open wherever you have saved your X code project I saved mine in My Documents folder

4
00:00:22,540 --> 00:00:26,490
and you're also going to need to pull open a terminal window like so.

5
00:00:26,770 --> 00:00:31,090
Now what we're going to do is we're going to change directories into our project folder and we're going

6
00:00:31,090 --> 00:00:32,020
to run a command.

7
00:00:32,020 --> 00:00:33,940
So go ahead and type CD.

8
00:00:34,090 --> 00:00:34,950
Create a space.

9
00:00:34,960 --> 00:00:39,310
And then what I like to do is just to simply drag the folder onto the terminal window.

10
00:00:39,310 --> 00:00:42,010
And that saves me from having to type out all of this.

11
00:00:42,130 --> 00:00:43,180
That's just what I do.

12
00:00:43,180 --> 00:00:48,250
So go ahead and press enter and you'll see we are now inside the versey app folder.

13
00:00:48,250 --> 00:00:56,350
Now to set up a pod file all we need to do is type pod in it and that will initialize an empty pod File

14
00:00:56,350 --> 00:00:56,860
for us.

15
00:00:56,860 --> 00:01:02,710
But what we need to keep in mind is that we might not have cocoa pods installed and if you started at

16
00:01:02,710 --> 00:01:07,420
the beginning of this video or sorry at the beginning of this course and you didn't have cocoa pods

17
00:01:07,420 --> 00:01:08,730
installed I showed you how.

18
00:01:08,890 --> 00:01:13,960
But just in case you do not still or you're starting a little bit later maybe you skip some of the beginner

19
00:01:13,960 --> 00:01:23,530
stuff you can simply type pseudo gem install cocoa pots press enter and it will install cocoa pods for

20
00:01:23,530 --> 00:01:26,840
you after you and to your administrator password of course.

21
00:01:26,860 --> 00:01:33,070
So I have it installed so I'm going to type pod in it and when I press Enter you'll see nothing happens

22
00:01:33,070 --> 00:01:36,180
here but a new file is created.

23
00:01:36,310 --> 00:01:39,650
I need to edit this and add in the pods that I want.

24
00:01:39,670 --> 00:01:43,840
Arik swift Arc's Cocco Alamo fire and Alamo fire image.

25
00:01:43,960 --> 00:01:49,240
So I'm going to go ahead and right click on my pod file since there's not a default extension and I

26
00:01:49,240 --> 00:01:50,920
need to open it with a text editor.

27
00:01:50,920 --> 00:01:58,300
Now you can use Adam you can use sublime text you can use brackets whatever text editor you want although

28
00:01:58,300 --> 00:02:04,780
I would advise against using text edit because sometimes in text it the formatting can get a little

29
00:02:04,780 --> 00:02:12,640
screwed up and some of the quote marks that you need to denote the pods in your file can sometimes be

30
00:02:12,640 --> 00:02:17,850
replaced by the stylized ones that are Antos on the side and we need the straight up single quotes.

31
00:02:17,950 --> 00:02:24,380
So that's why I like to use Adam because Adam instinctively can use the proper quotations that we need.

32
00:02:24,490 --> 00:02:26,500
So go ahead and pull that open.

33
00:02:26,500 --> 00:02:28,990
And this is what your pod file looks like.

34
00:02:28,990 --> 00:02:31,410
Let me zoom in here so you can see it.

35
00:02:31,420 --> 00:02:31,920
There we go.

36
00:02:31,960 --> 00:02:32,460
OK.

37
00:02:32,530 --> 00:02:33,520
Very very cool.

38
00:02:33,520 --> 00:02:35,380
This is what a pod file looks like.

39
00:02:35,380 --> 00:02:37,230
It says Target versey app.

40
00:02:37,330 --> 00:02:41,550
K that's the name of our project and it says do and that's where it's basically going to look through.

41
00:02:41,560 --> 00:02:45,760
Find our pods and install them when we run the proper command in the terminal.

42
00:02:45,760 --> 00:02:50,040
Now below this comment line is where it says pods for versey app.

43
00:02:50,170 --> 00:02:54,760
And what we're going to do is we need to get those and we need to install them so we already installed

44
00:02:55,180 --> 00:03:02,080
cocoa pods for swift and Arc's cocoa and we can do that again by simply indenting and typing pod dash

45
00:03:02,620 --> 00:03:06,630
Arek swift pod dash dash.

46
00:03:06,640 --> 00:03:15,550
It's like the single quote mark our X Ko-Ko we need pod dash Alamo fire and POD dash.

47
00:03:15,550 --> 00:03:19,450
I keep saying dash I mean quote Alamo fire.

48
00:03:19,470 --> 00:03:22,030
Image OK just like that.

49
00:03:22,030 --> 00:03:29,070
And if we go ahead and save this and quit it now we have a POD file containing the information we want.

50
00:03:29,290 --> 00:03:37,320
So if we go over here to the terminal now and type pod install and press ENTER watch what happens it's

51
00:03:37,320 --> 00:03:44,400
getting Alamo fire 4.5 Alamo fire image three point two arcs Coco and Eric swift Now those are the most

52
00:03:44,490 --> 00:03:48,230
updated versions on get hub which is really cool.

53
00:03:48,240 --> 00:03:54,460
It also says Please close any current X code sessions and use the versey app dot C workspace.

54
00:03:54,600 --> 00:03:59,820
From now on that's what we got to do so we can actually quit terminal at this point and we can go ahead

55
00:03:59,850 --> 00:04:01,630
and open versey app.

56
00:04:01,670 --> 00:04:06,540
X-Sea workspace and you might notice it doesn't look that much different but now we have a secondary

57
00:04:06,540 --> 00:04:13,200
project in here called Pod's and before we do anything we need to actually fix some of our Pod's because

58
00:04:13,440 --> 00:04:22,400
since we're running X 9 right x code 9 it's expecting that anything in this is using swift for but are

59
00:04:22,450 --> 00:04:28,650
swift are x Cocco Alamo fire and Alamo fire image have not yet officially released their swift four

60
00:04:28,710 --> 00:04:35,180
versions of those frameworks so we need to basically change them so that they are using swift 3.2.

61
00:04:35,190 --> 00:04:40,020
We can kind of support backwards compatibility and X code which is actually really cool.

62
00:04:40,020 --> 00:04:46,320
So go ahead and select the POD's project and you'll see we have four pods here and then one Pod's project.

63
00:04:46,320 --> 00:04:51,420
But what we're going to do is we're going to select each one like so go to build settings and then we're

64
00:04:51,420 --> 00:04:58,050
going to search for a swift language and you'll notice that it's asking it to use swift 4.0 but Alamo

65
00:04:58,050 --> 00:05:00,150
fire does not yet support swift 4.0.

66
00:05:00,150 --> 00:05:02,620
So actually you know what if we were to build this.

67
00:05:02,760 --> 00:05:07,050
You'll notice we're going to get a ton of errors in our swift.

68
00:05:07,050 --> 00:05:08,730
We'll get some in Alamo fire as well.

69
00:05:08,730 --> 00:05:13,660
So you know what we're going to do is we're just going to change all of these to use with 3.2.

70
00:05:13,680 --> 00:05:17,650
So go ahead and choose all of them and select swift 3.2.

71
00:05:17,910 --> 00:05:23,580
And just like so and now and now that we've done that we can go ahead and clean by doing shift command

72
00:05:23,580 --> 00:05:27,040
K and then hold command B to build the project.

73
00:05:27,210 --> 00:05:29,390
And you'll notice those areas are going to go away.

74
00:05:29,590 --> 00:05:30,360
OK.

75
00:05:30,720 --> 00:05:32,850
We still get some warnings and that's OK.

76
00:05:33,000 --> 00:05:37,470
But that's something with our ex-wifes So that's not something we did.

77
00:05:37,620 --> 00:05:39,250
So it's ok now.

78
00:05:39,330 --> 00:05:43,290
It'll build and then after it's done building we should get build succeeded.

79
00:05:43,290 --> 00:05:50,220
We should be able to use all of these different projects are swift as well as Ark's Cocco even though

80
00:05:50,220 --> 00:05:54,490
we'll get some mornings we'll be able to use them which is kind of the main point here.

81
00:05:54,600 --> 00:05:59,220
So we're going to go ahead and just let it do its thing finish building and then after that we're going

82
00:05:59,220 --> 00:06:01,400
to go ahead and move on to the next video.

83
00:06:01,410 --> 00:06:06,780
So we're almost done build succeeded our errors have gone away.

84
00:06:06,960 --> 00:06:08,810
Even a lot of our warnings have gone away.

85
00:06:08,810 --> 00:06:13,800
It's had a chance to look through and realize that it's all good to go as far as three goes.

86
00:06:13,980 --> 00:06:19,920
So we can close pods open versey app open the versey app group and we're good to go.

87
00:06:19,920 --> 00:06:25,590
We're going to start building our UI in the next video and we'll get to code very very shortly.

88
00:06:25,590 --> 00:06:27,970
Nice job with this video and I'll see in the next one.
