Session 2: Command Line

Track, organize and share your work: An introduction to Git for psychological research

Course at University of Hamburg

Slides | Source

License: CC BY 4.0 DOI

April 15 2024 (12:15 pm)

1 Admin

Schedule

No Date Title Contents Reading Survey/Quiz
1 2024-04-08 Introduction to version control Organisational matters
Overview of seminar sessions
Introduction to version control
Introduction to Git and its advantages
Intro to version control Course introduction Survey
2 2024-04-15 Command line File Systems
Benefits of the Command Line
Basic Command Line commands
Command Line Command Line Quiz
3 2024-04-22 Setup + Git Fundamentals Installation and configuration of Git
Initializing a Git repository
Basic Git commands
Installation, Setup, First steps with Git Installation Survey, Git Basics Quiz
4 2024-04-29 Basic Git workflow Practicing basic Git commands
Ignoring files with .gitignore
Good commit messages
First steps with Git Git Basics Quiz
5 2024-05-06 Git Branching and Merging Understanding branches in Git
Creating and switching between branches
Merging branches
Resolving merge conflicts
Branches Git Branches Quiz
6 2024-05-13 Quarto Workshop Introduction to Quarto
7 2024-05-20 Whit Monday Cancelled
8 2024-05-27 Introduction to GitHub Introduction to remote repositories
Creating a GitHub account
Creating and managing repositories on GitHub
Pushing and pulling changes
GitHub Intro GitHub Quiz
9 2024-06-03 GitHub with collaborators Cloning a remote repository
Branching and merging in a collaborative environment
Pull Requests
GitHub Issues
Graphical User Interfaces (GUIs), e.g., GitKraken
GitHub Intro, GitHub Issues GitHub Quiz
10 2024-06-10 GitHub with the world Forking a remote repository
README files
Project Management
GitHub Intro, GitHub Issues GitHub Quiz
11 2024-06-17 Repetition and Practice Repetition and Practice
12 2024-06-24 Publishing Creating Tags with Git
Creating Releases with GitHub
Using Zenodo for scientific publishing
Licences
Citation Files
Tags and Releases
13 2024-07-01 Graphical User Interfaces (cancelled) Repetition and Practice
Introduction to using GUIs
Graphical User Interfaces
14 2024-07-08 Summary & Wrap-Up Course evaluation
Repetition and Practice
Introduction to using GUIs
Graphical User Interfaces

Clarification: “What happens if I miss a session?”

  • Short answer: If you miss a session, please review the materials and complete the tasks until next session.
  • We will list the workload (and any homework) explicitly for each session on the course website.

lennartwittkuhn.com/version-control-course-uhh-ss24/sessions/session02.html

2 Survey results

3 Last session

Last week’s learning objectives

After the last session, you should now be able to answer the following questions:

💡 You know what version control is.
💡 You can argue why version control is useful (for research).
💡 You can name benefits of Git compared to other approaches to version control.
💡 You can explain the difference between Git and GitHub.

4 Today’s session

Pair Programming (variant)

  • Find yourself in pairs of two
  • Complete the exercises together

This illustration is created by Scriberia with The Turing Way community. Used under a CC-BY 4.0 licence. DOI: 10.5281/zenodo.3332807

Course exercise: Building an online recipes book

Example: https://lennartwittkuhn.com/recipes

Today: The command line

Source: Wikimedia Commons (free license)

Learning objectives

💡 You can navigate directories using the command line
💡 You can use shortcuts like the tilde or dots to navigate your file system
💡 You can explain the difference between absolute and relative paths
💡 You can use arguments and flags to modify command-line commands
💡 You understand the concept of wild cards (*) and can use it for system navigation

Today’s chapter

lennartwittkuhn.com/version-control-book/chapters/command-line.html

Your turn

  1. Windows users: Make sure that Git for Windows is installed and set up!
  2. Content Review: Read the chapter “Command Line” in the Version Control Book
  3. Implementation: Try out the commands in the chapter! Play around! Have fun!
  4. Exercises: Complete the exercises in the survey

Ask questions!