Data_Science_Workshop_Git_Github
Data_Science_Workshop_Git_Github
Git GitHub
▶ Distributed version control system ▶ Web-based hosting service for Git
▶ Tracks changes in source code repositories
▶ Facilitates collaboration ▶ Adds collaboration features
▶ Project management tools
Why Version Control is Important
Git is the most widely used, but alternatives exist for various needs
Installing Git
Windows Linux
1. Download from git-scm.com ▶ Ubuntu/Debian:
2. Run installer sudo apt-get install git
3. Follow setup wizard ▶ Fedora:
sudo dnf install git
4. Verify: git --version
▶ Verify: git --version
Basic Git Commands - Part 1
Warning
Using git add . indiscriminately can lead to unwanted files being tracked.
Consider using .gitignore and more specific commands.
Basic Git Commands - Part 2
Tip
Use git add -p for more granular control over what you stage. It allows you to
review and stage changes chunk by chunk.
Branching and Merging
# Delete a branch
git branch -d < branch >
Remote Repository Commands & GitHub Integration
▶ https://swcarpentry.github.io/git-novice/key-points.html