Submitting Data Structures Assignments with Classroom 50

Classroom 50 uses the GitHub command-line tool, gh, together with the Classroom 50 student extension.

1. Check whether GitHub CLI is installed

Open a terminal and type:

gh --version

If this command works, continue to Step 2.

If it does not work, install GitHub CLI:

Mac with Homebrew:

brew install gh

Windows with WinGet:

winget install --id GitHub.cli

Linux: Install GitHub CLI using the instructions for your Linux distribution from the official GitHub CLI website.

After installation, verify it:

gh --version

2. Log in to GitHub

Run:

gh auth login

Follow the prompts and authenticate using the same GitHub account you use for this course.

3. Install the Classroom 50 student extension

Run:

gh extension install foundation50/gh-student

Verify that it is installed:

gh student --help

4. Finish and test your assignment

Before submitting:

  • Save all of your files.
  • Make sure your program compiles.
  • Run your program and test it.
  • Make sure your terminal is inside the correct assignment repository.

You can check the repository with:

git status

5. Submit your assignment

From inside the assignment repository, run:

gh student submit

Wait for the command to finish and read the output carefully. Make sure it does not report an error.

6. Submitting again

If you make additional changes before the deadline, simply run:

gh student submit

again from inside the assignment repository.

Troubleshooting

If you see:

gh: command not found

then GitHub CLI is not installed correctly.

If gh works but gh student does not, install the Classroom 50 extension:

gh extension install foundation50/gh-student

If you are unsure whether your submission worked, run gh student submit again and carefully read the resulting message.

Scroll to Top