Skip to content

Comprehensive Setup (Forking, Cloning, and Dev Environment)

ochan1 edited this page Feb 14, 2023 · 4 revisions

NOTICE: Please read the guide first before starting!!! Be familiar with the steps you will do before doing it!

  1. Make sure “Git” works and it is connected to your GitHub Account (there is a way to do this later on in this step-by-step guide [see (*)])
  2. Go to the repo main page here: https://github.com/TBP-IT/tbpweb
  3. In the top-right corner of the page, click Fork.

Fork Button

  1. Follow the screen prompts to Fork to ANY GitHub Account of your choice (personal or school-specific). If you get a selection of things to fork to, we recommend forking to the GitHub account itself.

    • But we do recommend using a GitHub you commonly use since switching GItHub accounts may be annoying
  2. After forking, do either:

    1. Create a Folder to later on store the Repo in (it will be a Folder and the Repo Folder inside)
      • OR
    2. Use the computer’s “root” folder or another place without a main folder
    • The final result would be this kind of directory: “TBPWeb_Folder/tbpweb”

      Why a Folder to put my local repository inside of?

      The reason you may want to make a Folder and place the Repo inside it is in case you need to make multiple local copies to avoid messing up the original GitHub code during experimentation, or have documentation located in the same place

      “checkout” and “reset” do exist, but I sometimes do make code comparisons to see which options are better for me, plus the internet doesn’t always exist for me It saved me a lot of headaches and it may save you some as well

  3. Open your Terminal (Windows Git Bash or Mac/Linux Terminal) and open the folder you just made in Step #5 (or wherever you want to place it) [it’s usually just a “cd” on the terminal]

  4. Follow the instructions to Clone from the Forked repository: https://docs.github.com/en/free-pro-team@latest/github/creating-cloning-and-archiving-repositories/cloning-a-repository#cloning-a-repository-using-the-command-line

    • You can choose to use GitHub Desktop or GitHub Terminal, but I do recommend taking this chance to understand the GitHub Terminal
    • (*) This is where you may be asked to login to your GitHub. Do so here.
  5. Follow the relevant instructions in your respective organization’s GitHub Repo to test out the Development Environment Setup

    • It’s in the “wiki” tab on top, and then “Setup” under the “Gude” on the right Table of Contents
      • TBP Wiki's Setup Page
      • Read the entire guide
      • Then, follow the instructions related to the Instructions part of the guide, referencing any related sections to setup your environment
      • Lastly, Follow the Development section of the “Setup” page (there is a “Development” section on the Table of Contents, but not that one).
      • You may use the Django command createsuperuser to create a Superuser if you want, or you can wait until development.