Tutorial Using GitHub - Easiest Way - *UPDATED 12/14*

Discussion in 'Resources' started by Monkey_Swag, Dec 30, 2014.

Thread Status:
Not open for further replies.
  1. Offline

    Monkey_Swag

    Before we get started I'd like to point a few things out:
    - This is a tutorial for Windows, but follow the similar steps and it'll work on other Operating Systems.
    - This is also a tutorial on the Eclipse IDE, but the steps are no different from IntelliJ, Netbeans, or any other IDE that you would be using.

    Hello everyone, so I have seen a few people struggle with GitHub, and today I will be showing you the easiest way of pushing your code onto your repositories.

    First off, you'll need the official GitHub application that can be found on the following pages:
    Click me for Windows
    Click me for Mac

    Now that you have installed the application, just start it up, log in, and you should be taken to a page like this
    Then click on the top-left plus button to add a repository. Make sure you remember where you saved it, you'll need this later on. For the sake of this tutorial, I am going to name my new repository 'Tutorial'. You can obviously name it whatever you'd like.

    After doing that, you will see this. (NOTE: This is a tutorial on pushing code to GitHub, not a tutorial on understanding its components or how it works. i.e: The purpose of .gitignore and .gitattributes).

    After you do this, you will need to find your JavaProject's folder. In Eclipse it is found in your C drive, then users, then whatever user you have your code on, then you should see a 'workspace' folder. (This is how it works on Eclipse, not too sure on other IDEs).

    Open up the workspace folder and find the project you want to push onto GitHub. For this tutorial, I made a project called 'Java'. Open up your project's folder, and you should see something similar to this. Now remember we had to remember where our GitHub application made our repository;'s folder, well go to there in a new window with your project's folder opened still. Now COPY AND PASTE (DON'T DRAG & DROP) your src folder into the folder that we made using the GitHub application.
    As shown here: http://gyazo.com/48fcceac320de60e318d2780aafc782d

    Now just add a summary & description of your new commit to the project. I just put a very simple summary & description for demonstration purposes. http://gyazo.com/4a8f426a257f854fa792c2b30af583cc
    After that, just click 'Publish Repository' on the top-right and wait for it to publish. Once published you can go to your GitHub repository, and BAM! It's there! You finally did it!

    That's pretty much it guys, if you have any questions please feel free to tag me and ask. If I did something wrong or if I have any grammar errors on this I'm sorry, I'm writing this at 2AM. Why? Because I can.

    Good luck!
     
    ChipDev and mrCookieSlime like this.
  2. I prefer BitBucket, but nice tutorial anyway.
     
  3. Offline

    Monkey_Swag

    @bwfcwalshy will check BitBucket out, looks pretty promising due to the fact you can have free private repos. Thanks for the feedback!
     
  4. You could also use EGit and do it in less than 15 seconds.
     
  5. Offline

    ChipDev

    But this is freaking easy, And its the most known one :p
     
  6. @ChipDev
    Easier than clicking your mouse a few times and entering the commit message? No..
     
  7. Offline

    Avygeil

    @Assist Pretty sure any GUI client is about clicking a few times and entering a commit message, as well as not being limited to Eclipse. ;)

    @Monkey_Swag Private repos is the main reason I use BitBucket. :)
     
  8. Offline

    xTrollxDudex

    :OOOOOO

    Open source ;-;
     
  9. @Avygeil
    What I meant was that EGit is built into Eclipse, requires no downloads or setup, and neither do the local repositories.


    @Monkey_Swag
    "then you should see a 'workspace' folder"
    The workspace folder can be called anything, "workspace" is the default name of the folder but you can create new ones.
     
  10. Offline

    Monkey_Swag

    @Assist all folders can be called anything, but even if someone did change the name of the folder, they would know what they renamed it to, thus knowing what the folder is/knowing its location
     
Thread Status:
Not open for further replies.

Share This Page