Release

March 23, 20232 Minute Read

Introducing the GitHub Classroom CLI extension for the GitHub CLI

We're thrilled to introduce the GitHub Classroom CLI extension for the GitHub CLI, designed to simplify the lives of teachers everywhere. With this powerful new tooling, teachers can create their own personalized workflows, as well as streamline any custom solutions they've already built.

To get started, ensure you have the GitHub CLI installed, then install the extension with the following command:
gh extension install github/gh-classroom

Command your Classroom

The GitHub Classroom CLI extension provides a suite of commands to help you navigate your classrooms and assignments with ease. Here's a quick overview of its capabilities:

  • gh classroom list: List all your unarchived classrooms
  • gh classroom view: Show the details of a classroom, such as its name, description, URL, and roster
  • gh classroom assignments: Display a list of assignments for a classroom
  • gh classroom assignment: Show the details of an assignment, such as its title, type, deadline, starter code URL, and number of submissions
  • gh classroom accepted-assignments: List your students' accepted assignments
  • gh classroom clone starter-repo: Clone the starter code for an assignment
  • gh classroom clone student-repos: Clone all your students' submissions for an assignment (a scriptable alternative to the Classroom Assistant desktop application)

To target a specific classroom, use the -c flag with each subcommand (retrieve a classroom's ID through selecting it in gh classroom ls or gh classroom view). In the absence of the -c flag, an interactive picker navigable with arrow keys will help you select the target classroom.

This collections of subcommands marks the beginning of our journey to deliver power features that save you time and enhance your workflows.

You can report issues or request features on our public repository, where we look forward to open sourcing the code in the coming weeks.

Share what you build with the GitHub Classroom CLI in our Global Campus for Teachers Discussions forum!

Subscribe to our developer newsletter

Discover tips, technical guides, and best practices in our biweekly newsletter just for devs.

By submitting, I agree to let GitHub and its affiliates use my information for personalized communications, targeted advertising, and campaign effectiveness. See the GitHub Privacy Statement for more details.

Introducing the GitHub Classroom CLI extension for the GitHub CLI - GitHub Changelog