4

I have an existing repository on BeanStalk. All I want to do is use an OS X app which will allow me to use a GUI (just as I can do on the web-based BeanStalk site), such as Tower or Sprout. Both want me to "clone" my existing repository.

Why do I need to do that, rather than just access it from the OS X app?

SpokaneDude
  • 4,856
  • 13
  • 64
  • 120

5 Answers5

3

Because that way, you can work locally on your clone, and then push back when you are ready.

This is related to the distributed nature of the VCS (Version Control System) used by Tower or Sprout (here "git").

See the difference between:

Community
  • 1
  • 1
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
  • Thank you both for responding... I can see now that since I'm using XCode 5's new, spiffy Source Control, I don't really need Tower or Sprout. In a round-about way, that's what I was trying to figure out. – SpokaneDude Sep 14 '13 at 18:19
1

Version Control has a different workflow than FTP. FTP is fairly simple; edit a file, then upload. You're done. That can also be a problem. The file on your computer matches the file on the hosting server...but your coworkers do not know that. That could be dangerous!

Version Control takes it to a whole other level. Everything is tracked. This allows for better team collaboration. Edits are shared with others and when there is a conflict it will be flagged.

Because it's a different workflow development is done exclusively on your computer. Cloning provides you a copy of all the files from the repository and then it places them on your computer in an area that Tower or Sprout can monitor. These tools will let you know when a coworker has pushed an update and then help you update your local files (and vice versa). These programs are essential to the workflow and should be turned on and used all throughout the day.

Many times my work has been overwritten with the normal FTP workflow. I've done the same to others. It is rare that I use FTP anymore. Cloning is your first step to get the files from the repository on your computer.

Hope this helped and good luck!

1

The whole idea of modern version control is that every developer (every user) gets his/hers own copy of project, his/hers own working copy (working area, worktree). This way one developer work is separated from other developers, and won't mess others work. (Of course version control system has also to have an ability to merge, i.e. join changes).

The whole idea of distributed version control is that every developer (every user) gets his/hers own copy of repository, his/hers own clone. This way one developer can work on series of steps, series of commits separated from other developers.

Note that if you have already cloned repository on your computer, all Git GUIs allows you to select existing Git repository (sometimes by launching from inside said repository) instead of creating fresh clone. Of course then you should remember to keep yourself up to date via fetch / pull, and keep your remote publishing repository up to date via push.


That said some git hosting sites / software forges include in their web interface ability to manage / edit repository from web browser. For example GitHub provides interface for creating, editing and other operations on files, creating branches and merging them; you can even provide change proposal on foreign repository via GitHub cloning and creating pull request for you.

Beanstalk also (from what they say in documentation) has some support for code editing (at the bottom of page, left column).

There are also tools like GitHub for Mac, but I don't know if it uses GitHub API to edit remote repository like via web browser, or like other Git GUIs require you to clone repository to desktop.

Of course it wouldn't work that way with Beanstalk-hosted repository; Beanstalk has thought some third party tools like Habichuelas or Magic Bean for iOS.

Jakub Narębski
  • 309,089
  • 65
  • 217
  • 230
0

There is nothing in git that requires this behavior. Odds are the apps you're trying to use just assume you're hosting your code remotely, such as on GitHub. If you don't have a remote repository then you should be able to just ignore these instructions.

Chris Hayes
  • 11,471
  • 4
  • 32
  • 47
0

It depends on the tools available on the system hosting the remote repository.

To be able to, for example, view the version history of a remote repository, something running on the remote system has to run the git log command or equivalent. You can't just run the git log command yourself; that only works on your local system, and only if your current directory is within a git repository.

If you're interested in examining a repository on a remote system and that remote system provides appropriate tools built on top of git, then you don't need to clone the repository. For example, GitHub provides a web interface (which, behind the scenes, presumably is running git log and other commands on repos stored on GitHub's servers).

If you want the full power of Git, you can clone the repository (copy it to your own local system) and run git ... commands locally. But of course most of those commands (other than git pull, git push, etc.) won't affect the remote repo.

That's pretty much how Git and other distributed version control systems are designed to work.

Keith Thompson
  • 254,901
  • 44
  • 429
  • 631