Skip to content
Snippets Groups Projects
Commit e841cace authored by Pregmodder's avatar Pregmodder
Browse files

Merge branch 'clarifyDocumtation' into 'pregmod-master'

Clarify documtation

Closes #3462

See merge request !10237
parents c4b4236c 81c14b0f
No related branches found
No related tags found
1 merge request!10237Clarify documtation
Pipeline #42596 passed
...@@ -19,10 +19,16 @@ To effectively work on the project the following tools are required: ...@@ -19,10 +19,16 @@ To effectively work on the project the following tools are required:
### Setting everything up ### Setting everything up
0. Clone the project from GitGud.io ([Detailed Git setup and work cycle](devNotes/gitSetup.md)) 0. Clone the project from GitGud.io ([Detailed Git setup and work cycle](devNotes/gitSetup.md))
1. Open a terminal (Linux) / cmd window (Windows) and navigate to the `fc-pregmod` root directory. 1. Open a terminal (GNU/Linux) / cmd/Powershell window (Windows) and then navigate to the `fc-pregmod`
root directory via `cd PATH`. e.g.
Windows: `cd C:\path\to\project\fc-pregmod`
GNU/Linux: `cd /path/to/project/fc-pregmod/`
2. Run `npm install` 2. Run `npm install`
3. Open the directory in your preferred IDE 3. Open the directory in your preferred IDE
4. Configure your IDE to use ESLint and the type checking capabilities of the TypeScript compiler. 4. Configure your IDE to use ESLint and the type checking capabilities of the TypeScript compiler.
5. It might also be worth installing the following extensions if using VS Code:
[Code Spell Checker](https://marketplace.visualstudio.com/items?itemName=streetsidesoftware.code-spell-checker) and [GitLens — Git supercharged](https://marketplace.visualstudio.com/items?itemName=eamodio.gitlens).
## Compiling ## Compiling
......
...@@ -2,58 +2,52 @@ ...@@ -2,58 +2,52 @@
## First time setup ## First time setup
1. [Install Git for terminal](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) or a Git GUI of your 0. [Install Git for terminal](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) or a Git GUI of your
choice. choice.
2. Create an account on gitgud if you don't have a usable one. 1. Create an account on gitgud if you don't have a usable one.
* (optional) Add an SSH key to your account for easier pushing. This allows you to connect to gitgud through SHH, * (optional) Add an SSH key to your account for easier pushing. This allows you to connect to gitgud through SHH,
which doesn't require your credentials every time. which doesn't require your credentials every time.
5. Fork the main repository through gitgud interface. 2. Fork the main repository through gitgud interface.
* (optional) Delete all branches other than pregmod-master, so you don't get them locally when fetching. * (optional) Delete all branches other than pregmod-master, so you don't get them locally when fetching.
3. Clone the repo 3. Clone the repo and then change to the new directory
* Via terminal: `git clone --single-branch https://gitgud.io/pregmodfan/fc-pregmod.git` * Clicking on the dropdown arrow on the far right blue clone button in the gitgud interface on your fork gives you the relevant URLs.
* Via terminal: `git clone --depth --single-branch 1 <url-to-your-fork> && cd fc-pregmod`
4. Get updates 4. Add the main repository as a remote target
* Via terminal: `git pull` * Via terminal: `git remote add upstream https://gitgud.io/pregmodfan/fc-pregmod.git`
6. Setup your fork as a remote
* Rename the main repository to upstream
* Via terminal: `git remote rename origin upstream`
* Add your repo as remote
* Via terminal: `git remote add origin <url-to-your-fork>`
* The big clone button in the gitgud interface on your fork gives you the relevant URLs.
7. Checkout `pregmod-master`
* Via terminal: `git checkout pregmod-master`
8. Make sure `fc-pregmod` tracks `upstream/pregmod-master`
* Via terminal: `git branch -u upstream/pregmod-master`
## Typical cycle with Git: ## Typical cycle with Git:
1. Get changes from upstream 0. Switch to the pregmod-master branch, then check for and merge any upstream updates
* Via terminal: `git pull` before updating your remote if any updates were avabile
* If you don't get new commits from `upstream` repeat steps 7 & 8 of the setup. * Via terminal: `git checkout -q pregmod-master && git fetch upstream && git merge upstream/pregmod-master && git push -q`
2. Checkout a new branch for your work 1. Checkout a new branch for your work
* Via terminal: `git checkout -b <branch-name>` * Via terminal: `git checkout -b <branch-name>`
3. Make your changes as you like 2. Make desired changes
4. Commit your changes 3. Add them to be committed
* Via terminal: `git commit <files>` * Via terminal: `git add *`
* Make the commit message useful (`Fix X`, `Add Y`, etc.) 4. Commit
* Make the commit message useful (`Fix X`, `Add Y`, etc.)
* Via terminal: `git commit -m "MESSAGE"`
5. (optional, but recommended) Run sanityCheck before final push to catch any errors you missed. 5. (optional, but recommended) Run sanityCheck before final push to catch any errors you missed.
* You can ignore errors that already existed * You can ignore errors that already existed
6. Push result into your forked repository 6. Push result into your forked repository
* Via terminal: * Via terminal:
* Initially `git push -u origin <branch-name>` * Initially: git push -u origin `git rev-parse --abbrev-ref HEAD`
* Afterwards `git push` will suffice. * Afterwards `git push` will suffice.
7. Create merge request through gitgud interface. 7. Create merge request through gitgud interface.
* Suggestion: Tick "Delete source branch when merge request is accepted."
to help automatically tidy up your fork.
8. Checkout `pregmod-master` in preparation of next change. 8. Checkout `pregmod-master` in preparation of next change.
* Via terminal: `git checkout pregmod-master` * Via terminal: `git checkout -q pregmod-master`
9. Once the merge request was accepted, delete your local branch. 9. Once the merge request was accepted, delete your local branch.
* Via terminal: `git branch -d <branch-name>` * Via terminal: `git branch -dq <branch-name>`
To get a list of all current branches run `git branch --list` via terminal.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment