Advertisement
thioshp

GIT - Initiate And Upload Your Own Repository

Feb 8th, 2016
167
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.98 KB | None | 0 0
  1. GIT: STEPS TO CREATE, INTIATE AND UPLOAD A REPO
  2.  
  3. DATE: 02/09/2016 02:48:41
  4.  
  5. GIT TO USE: /usr/bin/git (version 1.7.10.4) #INSTALL VIA TERMINAL, NOT THRU GITHUB
  6. confirm by running this line in a terminal
  7.  
  8. $ which git
  9.  
  10. git is /usr/local/bin/git
  11. git is /usr/bin/git #THIS WORKS PERFECTLY FOR ME, INCLUDING CLONING WITH HTTPS
  12. git is /opt/lampp/git/bin/git
  13.  
  14. STEP 1: GOT TO YOUR LOCAL GIT DIRECTORY
  15. $ gogit
  16. or
  17. $ cd ~/git-repos
  18.  
  19. STEP 2: CREATE A NEW DIR OR COPY DIR TO GITHOME
  20. $ cp ~/Downloads/skype-4.3.0.37 ~/git-repos/skype
  21.  
  22. STEP 3: CREATE A NEW REPO HERE
  23.  
  24. $ echo "# skype" >> README.md
  25. $ /usr/bin/git init
  26. $ /usr/bin/git add README.md
  27.  
  28. STEP 4: CREATE REPO ONLINE
  29. Visit your online GitHub Account eg https://github.com/thioshp/
  30. Create a new repo there (use button titled "Create new repo"
  31.  
  32. STEP 5: CHECK GIT STATUS
  33. $ /usr/bin/git status
  34.  
  35. STEP 6: COMMIT THIS REPO
  36. Use -m to pass a mesage to git ESPECIALLY IF YOU GET "NO EDITOR vi ERROR MESSAGE"
  37. $ /usr/bin/git commit -m "first commit"
  38.  
  39. STEP 7: TELL GIT WHERE TO FIND YOUR ONLINE REPO (where your repo will reside)
  40. $ /usr/bin/git remote add origin https://github.com/thioshp/skype.git
  41.  
  42. STEP 8: UPLOAD YOUR REPO
  43. $ /usr/bin/git push -u origin master
  44.  
  45. #GIT FEEDBACK
  46. Username for 'https://github.com': ******
  47. Password for 'https://your-account@github.com':
  48. Counting objects: 148, done.
  49. Delta compression using up to 2 threads.
  50. Compressing objects: 100% (147/147), done.
  51. Writing objects: 100% (148/148), 19.11 MiB | 60 KiB/s, done.
  52. Total 148 (delta 27), reused 0 (delta 0)
  53. To https://github.com/thioshp/skype.git
  54. * [new branch] master -> master
  55. Branch master set up to track remote branch master from origin.
  56.  
  57.  
  58. MORE THINGS THAT YOU CAN DO:
  59. A. Push an existing repository from the command line
  60.  
  61. /usr/bin/git remote add origin https://github.com/thioshp/skype.git
  62. /usr/bin/git push -u origin master
  63.  
  64. B. Import code from another repository
  65. Do this via a browser logged in to your repository
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement