git Dropbox integration
~/project> git initInitialize git repo in your local directory
~/project>git add .Add all the files to staging area
~/project>git commit -m"my initial commit into the repo"Make your first commit
~/project>cd ~/Dropbox/proj_bkp
~/Dropbox/proj_bkp>git init --bare projects.gitCreates a bare repo
~/project>git remote add origin ~/Dropbox/proj_bkp/projects.git
~/project>git push -u origin masterThats it and your project has a remote repo on dropbox, which can be used as a backup if your primary laptop is stolen or if you dont have access to it
How to get the repo to your secondary computer
~/bkp_computer> git clone ~/Dropbox/projects/projects.gitCreates a projects dir with all your files
Make some changes and commit those changes
~/bkp_computer> touch README
~/bkp_computer> git add README
~/bkp_computer> git commit -m"adding readme" READMEPush those changes to your remote repo hosted on Dropbox
~/bkp_computer> git push -u origin masterAnd when you have access to your primary laptop, you do a pull (which is an equivalent of svn update)
~/project> git pull origin masterWritten by Sai kumar
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
 #Git 
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#

 
 
 
