- create a github account using your k12.ca
- check your email for a new assignment in github called ICS2O-Fabroa and accept the assignment. This will generate a new repository for you
- From your repository StRobertCHSCS/ICS2O-fabroa-[your name], click on the Clone or Download button (the green one on the right) and copy the URL
- In vs code, load a new terminal, verify it is positioned in the default directory
- In terminal, clone your repository to your device
git clone [your repositoryurl]
- In vs code, got to
File -> open folder
and choose the new director created from the previous clone - repeat this for any computer you will be working on
- in the terminal
git remote add upstream https://github.com/StRobertCHSCS/ICS2O-Fabroa.git
IN the terminal, type:
git config user.name [yourgithub user name]
git config user.email [your user.email]
For each class you want to:
- pull any of my updates from the upstream
- pull any of your updates (if you made any changes from the another device i.e home)
- copy any example files from the master to your working directory
- edit files in your Working directory
- Stage and Commit your changes
- Push your changes to github
git pull upstream master
git pull origin master
You can use the Explorer in vs code or use the cp command in terminal when directed to copy files to the working directory
When working with class examples, make sure you are editing files in your Working directory
- click on the Source Control icon on the left in VS Code (the forked path under the search icon )
- any modified files should appear in the CHANGES section
- Stage your changes by clicking the + in the CHANGES section header
- commit your changes by typing in a message (short and descriptive) in the message box and then CTRL + ENTER.
-
make the changes to your code or other files
-
In the terminal (make sure you are in the directory of your project (type
pwd
on the terminal to verify your current directory): -
git add yourfilename
to stage single file orgit add -A
to stage all changes in the project then
git commit -m "type a short meaningful message in present tense about your changes"
- With the Source Control pane, click on ... (more actions ), choose
Push
- ensure that all changes have been committed
- in the terminal type
git push origin master