Join Joe Chellman for an in-depth discussion in this video Installing SourceTree, part of Version Control for Everyone (2015).
- Thankfully, to use version control tools you do not have to use the command line. In this course, we're going to be using SourceTree, a very nice and free graphical user interface for Git and Mercurial, two very popular version control systems out there. To get it, you go to sourcetreeapp.com and I wanna make a specific mention here for Mac users, there is a version of SourceTree in the Mac App Store, but you should not use that, it's old. So you wanna get the current stuff, which is only available direct from Atlassian here at sourcetreeapp.com.
So, depending on how you visit the site, whether you're on a Windows machine or a Mac, you're going to get a big friendly button for the platform of interest. So, I'm on a Mac, my big friendly button says, "Download SourceTree for the Mac," so if I click that, it will download a disk image. For Windows users, you'll get a big friendly button for Windows, and that will download a setup app. I can still download it from my Mac and you'll just get the .exe file which you can run to install SourceTree. For Mac users, it's a little different, and I'm visiting this on a Mac, so let's take a look at how to install it now.
After you've downloaded the app, you can go to your Downloads folder in your home directory, and open the sourcetree.dmg file, this happens to be version 220.127.116.11. So here we are, and then I can just drag this application icon onto this alias to my Applications folder. And that will copy the app into my actual Applications folder. With that done, I can close this window and go to Applications, and here is SourceTree. So I'm going to open this up, and here we are.
When you first launch SourceTree, you may see a prompt about the free license and needing to agree to the license agreement, but no big deal, you can just check that and get right in. It's possible that you'll see other prompts as well for things like adding remote accounts and whatnot. Just skip all that stuff and get right into SourceTree. So the first thing you'll want to do after launching SourceTree is visit its Preferances, here in the Mac version I have just gone to the SourceTree menu and chosen Preferences, it's called something a little different on Windows. You would go to the Tools menu and then choose Options.
And then put in your name and e-mail address. The reason for this is the collaboration that's built into version control. Every time you make a commit, that commit is going to be associated to the person who created it and how to reach them. In this case, it's gonna be you. So I'm gonna fill in my name and an e-mail address. You will, of course, wanna use a real one. And with that being done, you can close the Preferences and you'll be ready to go. Now, SourceTree is not the only game in town, so let's look at a few of the other options that are available.
First up is the native GitHub app. Made by GitHub and available for both Mac and Windows. It's free and it makes connecting to GitHub very easy if you're going to wanna share your projects on GitHub. You can use it without ever connecting to GitHub and it will work just fine, but it does make that very easy. These apps are free. Another option is SmartGit, it actually supports Git and Mercurial and Subversion. That's kinda nice. It is also available for multiple platforms.
Mac, Windows, and Linux. And then I have two more options for Mac users, one of which is called GitX, this is GitX-dev, which is a newer version of a very longstanding app in the Git world for the Mac called GitX. It's updated to be a little bit nicer, and, of course, it is free. And then, finally, there's Git Tower. This is Mac only, it's a paid app. I happen never to have used it myself but I hear a lot of good things about it, so it could be worth exploring and it has a free trial.
So, we're gonna be using SourceTree in this course, but any of these options will work, so if you think the user interface of SourceTree is a little funny, or you would just like to try some other software, and of course there are many more available on the internet, only a search away.
- Weighing the pros and cons of version control
- Installing SourceTree
- Writing in small and big chunks
- Committing changes
- Revisiting previous revisions
- Creating and merging branches
- Using version control with Word, Photoshop, Macaw, and WordPress
- Sharing version control projects