Explanation on setting up git <3
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
RedStealthDev 050df496b1
Added a what is git section
2 years ago
.gitignore <3 2 years ago
README.md Added a what is git section 2 years ago

README.md

How To Git <3

Table Of Contents

  1. Part 1 Setting up account
  2. Part 2 SSH keys
  3. Part 3 Setting up github desktop
  4. part 4 Finishing up
  5. Usage

Part 1 Setting up account

  1. First of all Register here.
  2. Ask your organization owner to add you to the organization you can move on after telling them.

Part 2 SSH keys

  1. Press the windows key, search for cmd and open the black box.
  2. Write ssh-keygen -t ed25519 -C "your_email@example.com" replacing "your_email@example.com" with your own and press enter.
    • Press enter on all questions.
  3. Press the windows key, search for services and press the blueish cogs.
  4. Scroll down and find OpenSSH Authentication Agent Right click and press Preferences.
  5. Open the StartMethod dropdown and select Automatic (Delayed start).
  6. Press apply then press start. you can now exit the Services app.
  7. Open File Explorer and navigate to C:\Users\"YOUR NAME"\.ssh.
  8. Make sure that you have File extentions enabled in the show menu of File Explorer.
  9. Now Make a file and name it config with no extention.
  10. Open config in notepad and write AddKeysToAgent yes.
  11. Now back in cmd write ssh-add .ssh/id_ed25519 and press enter.
    • You can close cmd now.
  12. Open this Link and press add key.
  13. Now in the .ssh folder we opened earlier you should find a ìd_ed25519.pub.
    • Open it and copy the contents.
  14. Paste the text from ìd_ed25519.pub in the big box on the ssh key page we opened and rename it to something relevant like laptop or school.
  15. Finish of this part by pressing the Add Key button under the big box.

Part 3 Setting up github desktop

  1. First of all if you havent gotten github desktop downloaded yet then download it here and install.
  2. On the welcome page that opens after installation press the gray text that states Skip this step
  3. Now fill in the user and email that you have for this page and press continue.
  4. Once your inside there will be three buttons press Clone a repository.
  5. Now open the url tab and contine here.
  6. Go to the homepage of this website and find the Organization tab on the left.
  7. Under the tab you should see a organization if you dont then ask your organization owner to add you again.
  8. Now open that organization and press the big text in the empty space with your projects name on it.
  9. Here you will have to find the https and SSH buttons and press the ssh one.
  10. Next to the SSH button you will now see a link. Copy that link and paste it in the url spot and change file location if needed.
  11. Press the clone button.

part 4 Finishing up

  1. Wait until you see that the spinning arrows have stopped and the text under says Last fetched just now.
  2. Open unity hub and press the down arrow next to open and select add project from disk.
  3. Find your project were you put it default dir is C:\users\YOURNAME\Documents\github\PROJECTNAME and select.

Usage

Table of Usage

  1. What is git?
  2. Commit Pull Push
  3. Branches

What is git

Git is a repository management system and can be explained as a google drive folder shared to everyone added to it.
But this drive folder is special because this folder can save your old changes additions and deletions of your files.
Lets say you added a image long ago that you think isnt needed anymore and decide to delete it.
But The whole program breaks and you nead that file back, so instead of remaking or finding it again you can yust use the special feature of git that allows you to undo the deletion and go back to before it happened.
This is one strength but not the only one that Git has and there is one more i want to explain.
So lets say that you are a big team of programmers that are working on a project but how would you go about getting the new code to work with the old.
That is were Git's feature called branches come in they are basicaly a copy of the main folder branches of with some new code like maby you make a script that handles the main menu.
And when that code is done you can do a merge/pull request and turn the branch around so that it connects back to the main project again.

Commit Pull Push

Branches