CISC 7332X T6 C02b: Individual & Team Assignment Submission
Transcript of CISC 7332X T6 C02b: Individual & Team Assignment Submission
![Page 1: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/1.jpg)
CISC 7332X T6
C02b: Individual & Team Assignment Submission
Hui Chen
Department of Computer & Information Science
CUNY Brooklyn College
9/4/2018 1CUNY | Brooklyn College
![Page 2: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/2.jpg)
Outline
• Git and individual & team assignment submission
• Assignments
9/4/2018 2CUNY | Brooklyn College
![Page 3: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/3.jpg)
Git and Github Classroom
• The instructor uses Github Classroom to manage team work and individual assignments
9/4/2018 CUNY | Brooklyn College 3
![Page 4: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/4.jpg)
Git
• Version Control System (VCS)
• Source Code Management system (SCM)
9/4/2018 CUNY | Brooklyn College 4
![Page 5: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/5.jpg)
Version Control System (VCS)
• Why do we need it?
• https://stackoverflow.com/questions/1408450/
9/4/2018 CUNY | Brooklyn College 5
“Have you ever:
Made a change to code, realised it was a mistake and wanted to revert back?Lost code or had a backup that was too old?Had to maintain multiple versions of a product?Wanted to see the difference between two (or more) versions of your code?Wanted to prove that a particular change broke or fixed a piece of code?Wanted to review the history of some code?Wanted to submit a change to someone else's code?Wanted to share your code, or let other people work on your code?Wanted to see how much work is being done, and where, when and by whom?Wanted to experiment with a new feature without interfering with working code?
![Page 6: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/6.jpg)
Working with VCS
• VCS provides a “centralized” location to store project files
• Versioned code, configuration files, build scripts …
• VCS tracks each contributors’ individual changes
• VCS helps prevent concurrent work from conflicting
9/4/2018 CUNY | Brooklyn College 6
![Page 7: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/7.jpg)
Basic VCS Operations
• Check out/update: copying the repository to the machine you are working at
• Check in/Commit: copying the changes you made to the repository and creating a new version
• Branch: create a new “child” development from a state of the repository
9/4/2018 CUNY | Brooklyn College 7
![Page 8: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/8.jpg)
Distributed Version Control
• Git is a distributed version control system
• Possible to commit locally without upsetting the others
• Allow more flexibility and support different kinds of workflow
9/4/2018 CUNY | Brooklyn College 8
![Page 9: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/9.jpg)
Example: Distributed Workflow
9/4/2018 CUNY | Brooklyn College 9
commits commits
Remote Repository
![Page 10: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/10.jpg)
Merge Conflict
• A merge conflict may occur, e.g., when two branches contains edits to the same file
• Using this reference, see if you can resolve a merge conflict
• https://help.github.com/articles/resolving-a-merge-conflict-using-the-command-line/.
9/4/2018 CUNY | Brooklyn College 10
![Page 11: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/11.jpg)
A Simple Git Workflow
• Assume without merging
• git clone … (clone the remote repository to your computer)
• … Do something
• git add … (Add file contents to the index and to prepare the content staged for the next commit)
• git commit (Stores the current contents of the index in a new commit along with a log message from the user describing the changes.)
• git push (Updates remote repository using local repository)
• git pull (Updates remote refs using local refs, while sending objects necessary to complete the given refs. Attempt this when git push fails; do it before you start working …)
• … Do something
• git add …
• git commit …
• git push …
9/4/2018 CUNY | Brooklyn College 11
![Page 12: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/12.jpg)
Recommended Tools
• Git client
• Atom editor
9/4/2018 CUNY | Brooklyn College 12
![Page 13: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/13.jpg)
Verify Whether You Have Git Client• Verify if you have had the Git client
installed already
• Windows
• Attempt to run “Git Bash”
• Unix (OS X or Linux):
• Open a terminal window
• Run “git --version”, i.e., type “git --version“ (without quotes) and hit the Enter key
9/4/2018 CUNY | Brooklyn College 13
![Page 14: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/14.jpg)
Have I Had Git Client Installed?
• Windows and Unix
• If not, download and install it
9/4/2018 CUNY | Brooklyn College 14
$ git --versiongit version 2.17.1
![Page 15: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/15.jpg)
Download Git Client
• Visit https://git-scm.com/downloads using your favorite Web browser
9/4/2018 CUNY | Brooklyn College 15
![Page 16: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/16.jpg)
Git Bash on Windows
• Provides a terminal where you can run Unix commands
• The instructor shall use the Git Bash from now on so that the instructors are (more or less) identical to both Windows and Unix (e.g., OS X) users
• Window users: Use the Git Bash terminal
• Unix users: just use your terminal
9/4/2018 CUNY | Brooklyn College 16
![Page 17: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/17.jpg)
Verify Whether You Have Atom Installed• Verify if you have had the Atom editor
installed already
• Type atom on the Command Line
9/4/2018 CUNY | Brooklyn College 17
![Page 18: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/18.jpg)
Download and Install the Atom Editor• If you have not had the Atom Editor
installed, download and install the Atom editor
• Visit https://atom.io/ using your favorite Web browser
9/4/2018 CUNY | Brooklyn College 18
![Page 19: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/19.jpg)
Don’t Forget …
• Don’t forget to restart the Git Bash terminal before you verify again whether you have had the Atom editor installed
9/4/2018 CUNY | Brooklyn College 19
![Page 20: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/20.jpg)
In-Class Exercise C02b-1
• Warmup exercise for an individual
9/4/2018 CUNY | Brooklyn College 20
![Page 21: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/21.jpg)
In-Class Exercise C02b-2
• Warmup exercise for a team/group
• Now is the time to complete the “Team Composition form”
9/4/2018 CUNY | Brooklyn College 21
![Page 22: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/22.jpg)
In-Class Exercise C02b-3
• Locate and view your grades in Blackboard
• What do you observe?
9/4/2018 CUNY | Brooklyn College 22
![Page 23: CISC 7332X T6 C02b: Individual & Team Assignment Submission](https://reader033.fdocuments.net/reader033/viewer/2022060618/62972136e71e226ca17090da/html5/thumbnails/23.jpg)
Questions?
• These are difficult. I have many questions …
• There are too many exercises … (you and you team should complete them in your own time)
9/4/2018 CUNY | Brooklyn College 23