Advertisement
Guest User

Git

a guest
Sep 24th, 2013
49
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. My idea of process to use Git :
  2. Existing production Server : /data/web/monsite
  3. Copy of monsite to my local /Users/guillaume/site/monsite
  4. Local :
  5. cd /Users/guillaume/site/monsite
  6. git init
  7. git add .
  8. git commit -m "Initialization"
  9.  
  10. Production Server :
  11. cd /home/git/
  12. mkdir monsite.git
  13. cd monsite.git
  14. git init --bare
  15.  
  16. Local :
  17. git remote add origin ssh://IP/home/git/monsite.git
  18.  
  19. Send my modifications (and so monsite) :
  20. Local :
  21. git push origin master
  22.  
  23. Production Server :
  24. cp -R /data/web/monsite /data/web/monsite_sov
  25. rm -R /data/web/monsite
  26. git clone /home/git/monsite.git /data/web/monsite
  27.  
  28. ---
  29.  
  30. So after I can git pull origin master and push my modifications
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement