Learn by doing at Cal Poly with GitHub and Raspberry Pi

Professor Chris Lupo has taught at California Polytechnic State University for eight years and recently revamped his upper-level Architecture course using GitHub Classroom. In this post, he shares his workflow for deeper insight into student work, efficient debugging, and community support.


Open tools lead to a hackable classroom practice

At California Polytechnic State University, the motto is “learn by doing”, so it follows that students learn with real-world tools, rather than with board work and problem sets.

There's evidence of this learning philosophy in the tools teachers choose—particularly in open source projects GitHub Classroom and Raspberry Pi.

In group work, we do a lot with Raspberry Pi and students get into the habit of making sure they push to get it on their other systems, or so their partners can download changes. The flow encourages strong development habits. Push early, push often—that kind of thing.

Chris uses Classroom to distribute starter code and create individual and group assignments.

Diagnose, collaborate, fix: a debugging workflow that doesn’t hurt

Chris uses Classroom, GitHub’s collaboration features, and Raspberry Pi to work with students when they get stuck. Here's a quick overview of his workflow:

Quickly access a student repository. Assignments set up through Classroom automatically add Chris as a collaborator, and the dashboard clearly presents a list of student work.

b4ba24e8-4762-11e7-8349-7346ed232150

As soon as students click an “invitation link” from Chris, Classroom creates a new repository for them.
Here’s the output from GitHub Classroom in Chris’s course.

Clone and comment in-context. Students can see where changes need to be made and leaves comments directly in their code.

Test the fix on his own Raspberry Pi.

Push the code back to the student’s repository, with fixes and comments.

This workflow solves the cumbersome task of transferring files. Both instructor and student can work from their own environments, instead of switching between computers.

I can clone their work, connect to the Raspberry Pi that I have access to, and run their code. From there I can work with them directly on their code base to show them what steps to take and how to move beyond their current problem. After we work together, I can push the code back to them when we’re done.

I have access to everybody's code all the time. I've not had that capability prior to using GitHub Classroom.

An active community of teachers helping teachers

When Chris has questions about Git or best practices, he reaches out to the GitHub Education Community for advice from other teachers.

I've also found the community really helpful for support. For example, I learned about a script named orgclone that was really useful for me in repository management.

screenshot 2017-06-26 13 39 18

Even though Git and GitHub take some time to get students up to speed, Chris says students are happy with the experience now that he’s implemented GitHub.

Feedback has been very good. There is a little bit of a learning curve for people who have never used Git before, but they all said it was worth it.


Adapt Professor Lupo’s assignments:

Use Raspberry Pi assignments for a university setting:

See more GitHub Education posts

Sentry joins the Student Developer Pack

Sentry joins the Student Developer Pack

School may be (almost) out for summer, but we're still adding to the Student Developer Pack. Sentry is now offering error reporting to new and existing pack members—send up to 500,000 errors per month and enjoy unlimited projects and members.

Sentry provides real-time error tracking and crash reports for your web apps, mobile apps, games, and more. With Sentry, you get all the information you need to identify, reproduce, fix, and prevent bugs—from the full stack trace and the contextual details of the exception to a trail of events that led to the issue and release and commit data—so you can set priorities, triage proactively, and make sure errors don't affect your user's experience.

Sentry works with dozens of languages, frameworks, and libraries, including JavaScript, Python, Ruby, PHP, Node, Java, Go, and Swift—and it's 100% open source. Sentry also integrates with GitHub to create issues based on Sentry events.

Sign up for the pack now.

GitHub Student Developer Pack

Our Student Developer Pack gives students free access to the best developer tools from different technology companies like DigitalOcean, Datadog, Stripe, Travis CI, Sentry, and more. Oh yeah, and all students get free unlimited private repositories—perfect for summer projects.

How to grade programming assignments on GitHub

Feedback is essential to the learning process. Input from an expert at the right time can make all the difference in a software project.

In past programming classes, Professor John David N. Dionisio's printed out student assignments and commented on their code by hand, directly on the paper. Students said it was easier to understand feedback when it was in context.

When he started using GitHub’s interface to communicate with his students, he found he could introduce version control even earlier in his courses. As a result, Dionisio's students have the opportunity to use industry tools from day one of their studies.

The web app has made development more accessible sooner, letting freshmen get in on it without having to learn everything about version control. The comment threads and the ability to comment line by line tightens the feedback loop. Now printing is not really necessary because you can just look at the diffs and make comments about it.

With a streamlined process, students don't get stuck on setup

John runs his courses using GitHub Classroom to manage student assignments and Jenkins CI to deliver immediate and ongoing feedback.

Working with a live repository, he knows students will see it exactly as he does. And GitHub Classroom’s dashboard lets him share a link to the full assignment and view who has accepted it.

For students it’s easy to get started. With Classroom, I can now basically deliver a complete package, including the instructions. Instead of things being sort of scattered, and having the student accumulate it together. Documentation is there, sample code is there, and configuration files for continuous integration are there.

Every student picks it up, and if they’re off and running. They can commit, and you can look at their histories. Students have their own private repo that they would build their files on.

More substantive feedback, fewer syntax errors

Until he started using Jenkins to flag formatting issues, Dionisio had to provide his students with a flood of stylistic comments.

Now, instead of focusing on bad indentations and incorrect spacing, Dionisio can give more qualitative feedback on redundancies and best practices. His comments have evolved into more of a conversation.

I frequently give feedback in terms of design and structure, like "I would’ve instead written this line this way." And since GitHub comments are in Markdown, they're easy to read and very clear.

You can really format the code and convey your ideas. The display thread helps the student respond. It allows very context-sensitive, context-aware discussions for finer points of code.

The difference reviewing code on GitHub makes
A before and after of Dionisio's feedback—from manual markup to precise and contextual feedback using GitHub’s review process.

github-annotated-json-error copy
github-explain-linting-notes copy
github-pinpoint-focus-on-bug copy
A few additional examples of John's feedback to students.

The goal: strong communication skills around code

In industry, developers almost never start from scratch. To be successful, they need to be able to ask questions about code, to understand what’s going on, and recognize the strategies of other developers. In the classroom, pull requests work to build those skills:

Pull requests with Markdown support are a great place to have a consistent thread of feedback. And this clear signal of, "I now accept your work"—like building a relationship of submitting your work for someone to look at, and after we workshop it for a little bit, I now accept your work.

Anything that helps me simulate tools and practices they will encounter later is always of help.


This is a post in our “Teacher Spotlight” series, where we share the different ways teachers use GitHub in their classrooms.

See more GitHub education posts

Teaching recursion with fractals at Lowell High School

art_simon

Mikaela Marciales, a junior at Lowell High School in San Francisco and member of the JROTC, reflects on her projects in AP computer science as equal parts expression and fun—in large part thanks to a creative AP computer science approach developed by her teacher, Art Simon.

When I’m feeling all optimistic and happy, I’ll make a really colorful, explosive program. If I'm more calm, I'll make a more minimalistic type program.

Spark curiosity in your course design

Years ago, Art remembered that a student brought in some code he ripped out of a magazine. After they ran the code together, the student’s eyes lit up.

From there on out, Art has designed assignments for students to make work theirs, put personal touch on projects, and build things that are meaningful.

Programming is about making the computer do what you want it to do. So personalize your projects. Make them fun. Make them unique. When students can make it theirs, you tap into another kind of creative design and drive.

Rethink recursion assignments

Recursion is a critical programming concept, but it can be pretty abstract. In Mikaela’s words, her first introduction to recursion was, “Wow, this must be super complicated.”

But Art showed students fractals and prompted students to create their own. With a touch of Algebra and looking at a few lines of sample code, Mikaela jumped in to make her own Sierpinski Triangle.

triangle
See Mikaela’s project on GitHub Pages

Now Mikaela is even looking at nature differently.

Whenever I think of recursion, now I think of nature and tree rings, Mr. Simon showed us this picture of a leaf that is a leaf inside of a leaf inside of a leaf type thing. I think I've seen it in a lot of plants now that I think about it.

Unique projects make cheating difficult

Art encourages his students to look at similar projects on GitHub for inspiration and to ask other students for input.

Mikaela reflects on this blend of studio feedback and peer learning:

Having people that I talk to is really nice because, you can just say, "Oh, that would be really cool in your program." And someone will tell me, "Oh yeah that would be cool in your program, too."

mikaela asteriods 3
Mikaela built on what she’d learned in Java programming for her future assignment Asteroids.

He structures the assignments in terms of milestones, layering in a different element or feature of the project at each turn.

In Mikaela’s Asteroids game, we're using object oriented programming techniques that build up and adds features. We get the ship working first. That's milestone number one. We get the asteroids on the screen. That's milestone number two. We get the ability to remove asteroids and look for collisions. That'd be milestone number three. Then we add bullets, and you got a working game.

Since everyone’s project is unique, Art isn’t concerned about dishonesty—as long as students can explain what is going on in the program, they’ve mastered the material.

People are going to create objects that explode differently and encounter collision detection differently.

A passionate start to a career in programming

Mikaela has run out of computer science courses to take at Lowell, but she participates in an after-school program called Mission Bit and plans to continue with an engineering internship this summer. And Mr. Simon’s approach to teaching has made all the difference:

I have to compliment Mr. Simon because I was a complete beginner in all of this stuff when I came into it, and he taught me everything, which is pretty cool because now I know so much.

Resources for AP Computer Science teachers


This is a post in our “Teacher Spotlight” series, where we share ways teachers use GitHub in their classrooms.

See more GitHub Education posts

How investing in teaching with GitHub pays off

How Harvard, San Francisco State, and The College of New Jersey use GitHub in their courses

As a teacher, you juggle the endless stream of student emails, faculty responsibilities, and an ever-evolving field of scholarship. Is it worth to switch to version control for your courses? What do students get out of it?

Three teachers candidly reflected on the benefits GitHub offers their classroom practice at the recent Special Interest Group on Computer Science Education conference (SIGCSE) in Seattle.

Skip to a specific section:

  • 2m24s Omar Shaikh (SFSU): GitHub + Travis CI for automated grading
  • 11m50s S. Monisha Pulimood (TCNJ): Collaborating on real-world projects
  • 23m28s David J. Malan (Harvard): Custom tools for CS50
  • 37m25s Questions and answers

Monisha Pulimood, Professor of Computer Science and Chair at The College of New Jersey, shifted her class on databases to a project-based model, where students collaborate in teams with a service learning component.

My concern was that, because of all the collaborative activities, I was losing class time for the students to actually master the content. But in fact, they are. It turns out they are really doing well with that; there’s a good increase in understanding the content. Students can answer deeper questions than they could before.

David J. Malan from Harvard University walked through the nuts and bolts of implementing Git and GitHub for CS50 in this deck.

CS50 Deck

Sign up for lesson plans, tutorials and best practices from GitHub Education

Once a month we’ll pass along tips and tricks for implementing Git and GitHub in your classroom.

Subscribe for updates

Why version control is required for Comp 20 at Tufts University

Ming Chow of Tufts gives advice on teaching Git and GitHub

Students don't leave Ming Chow’s course until they are prepared to hold their own on an engineering team. Full stop.

What’s required for those rigorous engineering roles? “Experience making tangible things, mastery of how the web works, and communication,” Ming affirms.

In 2016 he received both the School of Engineering Teacher of the Year and Excellence in Technology Education awards at Tufts, success he reached using GitHub:

I’ve used Git and GitHub for well over five years now. When you take a course with me, it is simply expected that you’re going to learn Git and GitHub.

Ming was inspired to put version control front-and-center in his curriculum from a colleague, Norman Ramsey, who posted the idea to Stack Overflow. “Norman is a man of many great ideas, and this was one of them. I took his idea and executed it.”

To collaborate, you must communicate

It’s rare that developers build something entirely on their own: whether it’s taking over legacy code, reading documentation or submitting bug reports, we’re always in dialogue with others.

The benefit of version control is that it takes snapshots of progress over time, and small commits with clear progress markers give context to your work. Training students to make commit messages that are clear and frequent pays off in the future when other developers are able chip in to help.

Just to make sure that students master collaboration, Ming designs assignments and group projects so students must rely on one another to distribute the workload. He also asks students to give context to their work with GitHub’s documentation features:

In every assignment and every lab, students have to write a README. And a lot of them ask, “Why the heck do we have to write that?” Well, the difference between a good engineer and a great engineer boils down to writing skill and communication. So that’s the whole point of having a README for every project.

chow-readme-example
Priming collaboration: GitHub users are invited to create a README for every repository.

Collaboration matters because the web is relationships

To demonstrate how web technologies are interrelated, Ming has students evaluate and use third-party tools like APIs, Heroku, and GitHub to build their projects.

As part of that process, students become wise about which APIs to rely on:

One of the nice things about this course is it reveals the ugliness of web development, especially if you’re using other people’s platforms and services. For instance, Instagram recently changed its policy on rate limits, which students had to adjust for in their projects. When you’re dealing with APIs, you’re at the mercy of that third party. In any job, you’ll need to learn how to deal with that kind of risk.

All that said, Ming recommends the third-party tool Heroku for student projects because students can use Git to push changes to a live product.

wikilinks

Screenshot from a COMP 20 project hosted on Heroku. With these end-of-semester projects, students demonstrate their ability to work in teams, apply everything they’ve learned in the class, and have fun.

phood

Screenshot of another COMP 20 project.

Last, Ming points to GitHub itself to show the moving parts of the web in action:

Git and the web are tightly integrated. One of the main points of using GitHub is to show it’s all based on HTTP and HTTPS. That also reinforces the learning of how the web works, as well.

Why is mastery of the fundamental pieces of the web important? Once students master the web conceptually, they will be able to integrate new technologies into this framework, building upon their understanding in the future.

Careers are the sum of our contributions

At the end of the semester, Ming celebrates the end of the course with perhaps one of the best subject lines of all time:

gift image

Ming frames student work as something that’s valuable and in moving a repo to their stewardship, he’s giving students the gift of a portfolio. In the future, students can point to this project as proof of how they communicate with other developers.

As their last assignment, he asks students to frame their repository with one last README: a self-assessments about what they’ve learned in the course. From a student:

The most important thing I learned has been the importance of communication in teamwork. For example, dealing with merge conflicts on GitHub was a big problem in my group, and helped us learn how to discuss our changes with each other, even as we were working on separate parts of the project. Another time we were struggling with making our database queries, and even those group members not working on the server side had to learn about it and help.

A duty to train future leaders

Git and GitHub reinforce the ability to communicate with others around real-life projects, which is why they are required for COMP 20.

Ming believes that teaching computer science is not simply about ones and zeroes but about leadership. The technology of the future relies on the habits he’s building in the classroom.

image


This is a post in our “Teacher Spotlight” series, where we share the different ways teachers use GitHub in their classrooms. Check out the other posts:

Join this week's discussion in the community forum: How do you introduce Git in your course?

GitHub Issues and user testing as authentic assessment

Alexey Zagalsky quote on learning process

A course organized around users, not exams

In his Startup Programming course at the University of Victoria, Alexey Zagalsky asks students to design products based on user needs.

Working together in teams of four to six, students deliver pieces of the project at key milestones:

He ties the course to the software industry by inviting experienced mentors from local startups to evaluate student work. Alexey says:

While the end-products are terrific, the larger goal is understanding the process of collaborative software development. Students learn how to listen to users and incorporate their feedback in a thoughtful way.

User testing as assessment

After students ship a working prototype, the next milestone requires user testing with their target audience. And of all the challenges over the semester, students wrestle the most with addressing user feedback:

The most frequent point of failure is not understanding their users. And they wouldn’t see where they’ve failed until they try to get people to use their product.

But being able to listen to feedback, and implement it as part of the design process, is quite important. First, to learn, but also to get a job, because it’s not about writing code but actually understanding what needs to be built and how. One student now works at Amazon. Two or three work at Microsoft. One has gone on to become a UX designer. So many students really benefitted from this approach.”

Feedback through GitHub issues

Alexey admits:

You’d be surprised how often students get stuck and never ask for help

So occasionally he pops into student repositories to see what’s going on, test the code himself, and spot mistakes before it’s too late.

If he spots a bug, he’ll open an issue, outline what’s amiss and upload screenshots of the behavior.

Alexey finds a bug in a student project
From the fall 2016 student project DayTomato.

Next, he works with the team to think about potential solutions:

One team wasn’t sure which metrics they should track using Mixpanel. I suggested they track certain metrics at the prototyping, release, and iteration phases of their project. I gave them some perspective on how to prioritize and implement.

Alexey comments on a student project
From another student group, who made a borrowing and lending application called Bümerang.

Iteration for intrinsic motivation

In an Agile classroom, the goal is not the right answer to the problem, but knowing which problem to take on first, and how to solve it in the right increments.

This course isn’t about assessing a final product and saying, ‘You did that wrong.’ Our in-progress ‘checks’ show the students we care about their work; it’s not just some assignment they need to submit for a grade. The way we care makes them more motivated in turn.”

screenshot of presentation on process

Another student project, SmirkSpace, reflecting on its user feedback for Milestone 3.

A collaborative classroom practice

Alexey’s research focuses on how to use industry tools to build software together, to help his students develop the social ties, trust and curiosity to sustain a successful software career.

So he uses GitHub to enable discovery, design, and collaboration:

It’s about changing the way people work: students and educators, students among themselves, and education’s relationship to industry.

I am working from the hypothesis that software built collaboratively, with many voices and opinions, will improve the collective good of future software, period.

How to implement this classroom practice

Alexey documents all of his course designs and publishes the results of his research on student experiences with GitHub, Slack, Stack Overflow and other real-world tools.

Here’s a recent talk on his course design that discusses the benefits (and drawbacks) of using social tools in the classroom:

Student reflections on tools ecosystem


This is a post in our “Teacher Spotlight” series, where we share the different ways teachers use GitHub in their classrooms. Check out the other posts:

Join this week’s discussion in the community forum: How do you use issues in your class?

Invest in tools students can grow with: GitHub and RStudio for data science at Duke University

quote from mine cetinkaya-rundel

Data science is a melting pot of disciplines: students from Anthropology to Political Science to Education all sign up for the same course. It’s a challenge to keep the material engaging for everyone.

At the same time, teachers want the next generation of data scientists to be able to analyze any dataset they come across in the future with the same level of rigor used in the classroom. That outcome requires a consistent level of training, across diverse datasets.

Mine Çetinkaya-Rundel, Director of Undergraduate Studies and an Associate Professor at Duke University, tackles these problems head-on. She quite literally wrote the book on the subject, and her open, online course Master Statistics with R certifies thousands of students a year. She edits the Citizen Statistician blog and offers the annual Duke DataFest, a hackathon for working with data.

Her data science course emphasizes “reproducible computation”, a documented process of how data is treated in order to replicate the results in the future. She meets that learning goal using R Markdown and R Studio, as well as by requiring students to incrementally commit their changes using Git and GitHub.

Students learn the concept and the real-world tool, at the same time

Some instructional products have a high learning curve in-and-of themselves. Çetinkaya-Rundel would rather students learn a language in the discipline that they can later build upon:

They learn a limited bit of R syntax that allows them to analyze and visualize data in R. While the goal of the course is not to make each student a proficient R programmer, they learn enough R to be able to build on in their second or third classes. Teaching software designed to be used only in an introductory class would not have this benefit.

rmarkdown

Editing an R Markdown file in RStudio by Chester Ismay, MIT License

She wants her students to ship their first visualization project quickly and get started “like a knife through butter” without errors. To bootstrap their efforts quickly, she has them access RStudio Pro using her department’s server.

Best practices for scaffolding collaboration

Sta112FS introduces Git on day one to help students learn about version control gradually and in increments. Her GitHub structure is one organization for the course, one repository per team, and one per assignment. She recommends starting out with an individual assignment first, so students can get used to Git’s mental model before adding the complexity of collaboration.

gitgithubhow
gitgithubwhy

Mine has students access their projects through RStudio, which she integrates with Git. These slides are from her talk, A first-year undergraduate data science course.

On group projects, Mine creates one repository per team, and everyone on the team can push. Knowing that students will encounter merge conflicts when they’re working asynchronously, she provokes the error messages early on in the semester.

In the first exercise, students clone a demo repository and are asked to edit the README in two tools, first on GitHub and then again in the RStudio editor. The conflicting changes throw an error, which she teaches students to resolve calmly, and by reading the messages.

I show them how I would resolve [the conflict], and then they do the same thing... I tried to create a situation in the classroom that could be frustrating for them later, and say, "This is about to happen. It's important to read the message that it sends you, and this is how you would resolve it.”

The setup pays off in engagement and curiosity

For Mine’s course, using a computation tool prompts students to engage with data directly—an important pedagogical choice to make their analysis both personal and real. There’s a freedom in exploring and tinkering with the real-world tool that professionals use.

Using a computational tool means that you can give the dataset to the students, and they can play around with it. They might be playing around with it in a way that you have designed the assignment or the assessment, but still it gives them the flexibility to look at another variable, make a different plot, than what was assigned for them to do.

Git and GitHub expertise after students leave the classroom

While she keeps student repositories private, merely using GitHub gives her students an edge later in their careers. They can also choose to make their repositories public after they are done with the course.

A lot of students have said to me later, even first-year undergraduates, that using GitHub has helped them a lot when they went for an internship or a research position interview.

They are able to say, "Oh, I already have worked with GitHub. I'm familiar with it. I know how it works.” So I think they are at least able to put that on their CVs and go into a situation where there's a research or data analysis team and say, "Yeah, sure. I am actually familiar with the same tools that you use."

Creating RStudio projects from GitHub repositories

To see an example of Git and RStudio in action, check out this tutorial from Dr. Nicholas Reich at UMASS-Amherst:


This is a post in our “Teacher Spotlight” series, where we share the different ways teachers use GitHub in their classrooms. Check out the other posts:

Join this week’s discussion in the community forum: What are your favorite Statistics/R/ GitHub Resources?

Real-time feedback for students using continuous integration tools

For teachers it can be a challenge to get students the help they need exactly when they get stuck, especially in large courses. But when teachers use an automated testing suite like Travis CI with their assignments, students can hone in on their mistakes and iterate to improve.

Students see the value of a test-driven workflow as they are learning, and teachers save time grading assignments: a win for everyone.

Omar Shaikh quote

Omar Shaikh, Lecturer at San Francisco State University, saw an opportunity to improve the assignment workflow for the C++ course he took over:

"The problem with the manual submission process was that, if a student is missing a small semicolon, or they were almost correct, the TA has no way of knowing because it doesn't compile. Yes, the TA can go into the code and try to grade it, but it's very inefficient."

Build confidence through passing tests

Exercism, a tool that helps code newbies and experienced programmers learn new languages, uses a testing framework to guide students in increments.

“It helps people who are new to programming break down problems into smaller pieces” said Exercism creator Katrina Owen, “a lot of students spent a lot of time being stuck before I introduced test suites. Seeing the green check marks when their tests pass can reassure students that they’ve mastered the skill and the problem is solved for now.”

Experienced Ruby teacher (and TravisCI engineer) Renée Hendricksen agrees: “When you have assignments that are ‘write code to get these tests to pass’ the student gets instant feedback if they are on the right track.”

“When you use a ‘test-first’ teaching method,” she explained, “students get used to reading and understanding errors early. When they start with a failing test, they can look into whether it’s an error because of setup or their application. Let the red-green-refactor guide you.”

Efficient grading for problem sets

Instead of grinding through a lot of time looking for a missing period or semicolon, teachers have insight into exactly which piece of the code didn’t pass and go from there.

For Hendrickson, a testing suite makes grading more efficient because she can see where a student needs help:

“If I see a failing test I can look there immediately and address where they struggled. If all the tests are green, I can focus on working code and give them guidance for style and composition improvement, without getting bogged down explaining syntax issues.”

A step-by-step guide to using tests for immediate feedback

Omar connects his course organization to GitHub Classroom, and then to Travis CI. While there are many ways to implement automated testing, here are the steps to implement his particular workflow:

Step 1: Create the tests

  • Make an organization for each class, and apply for the organization discount at the GitHub Education website.
  • Prepare homework assignments, their solutions, and test cases. For C++ assignments, Omar used Google's Gtest library for test cases. Create a private repository in the organization, and move homework files there.
  • Connect the assignment repository to Travis CI.

01 Create new assignment
Setting up a new individual assignment in GitHub Classroom

Step 2: Make the assignment and connect it to GitHub Classroom

  • Omar removes code segments so that students complete them as their homework. He includes a few lines of contextual information as comments embedded in code (such as “Complete this Section”), and creates a public repository with the name of the homework assignment: hwx-template (where x is the homework number).
  • Omar navigates over to GitHub Classroom, creates a new individual assignment, and points the assignment to the template repository.
  • Omar posts the assignment link from GitHub Classroom to his class forums. As students click on the link, Classroom creates a new private repository for each of them.
  • In Travis CI, Omar enables the tests on each of the student repositories. Travis will then build the repository after every push, based on the directions Omar put in the starter code template repository.

03 student repos in Travis
Example of a few student repositories on Travis CI for “hw3”

Step 3: Students clone the assignments and complete their homework using the recommended IDE

  • Omar uses the CLion C++ IDE from JetBrains, which offers free licenses for educators, and manages Google Tests efficiently.
  • Students clone their particular assignment repository with detailed instructions in the README.md.
  • Students open the project in the IDE to start coding and running unit tests. As students complete their assignments, they push their changes to GitHub.
  • Instructors can see if the build is passing via Travis CI and in the “commit” view on the GitHub web interface.

04 Passes student example
Graders can look at which tests failed for insight into where students struggle with the material

Use this workflow in your own course

If you’re ready to implement Travis CI and GitHub Classroom, here are some tools to get you started:

  • a sample repository you can use as an example with all the moving parts
  • a Travis build of that sample
  • Omar’s problem sets, which have been tested by his team of teaching assistants and also contain detailed instructions.

To help you put all of the pieces together, Omar made a video walkthrough:

This is a post in our “Teacher Spotlight” series, where we share the different ways teachers use GitHub in their classrooms. Check out the other posts:

Join this week’s discussion in the community forum: How to automatically gather or collect assignments?

How CS50 at Harvard uses GitHub to teach computer science

How does Harvard's largest course, an Introduction to Computer Science, use GitHub to achieve its learning goals?

Professor David J. Malan, Gordon McKay Professor of the Practice of Computer Science at Harvard University, is dedicated to offering his students a robust learning experience. This post outlines how he uses GitHub and his own custom tools to build hands-on assignments for CS50 students.

Using GitHub for CS50

With over 700 students, 80 staffers, and 2,200 participants in their end-of-term CS50 Fairs, CS50 has a reputation for rigor, real-life application, and engaging material.

At the same time, says Professor Malan, about half of CS50’s students typically treat the course as “terminal”— as their one and only course in computer science. So the projects touch on applications in a variety of fields, from social sciences and humanities to medicine and finance.

Malan says of the learning goals of CS50: “We want to provide students with a solid foundation in computer science so that they are well prepared for any field. And also bring to bear some practical skills to that world. So that is actually tied in with our adoption of GitHub this past year.”

A gentle onboarding to Git and GitHub

The mental model for cloning, branching, opening pull requests, or pushing can be tricky for newbies just starting out. As a way to onboard students, Malan wrote a command-line tool that wraps a sequence of Git commands called submit50. They developed submit50 to not “reinvent the wheel” with a new submission system, but to create space for students to grow into comprehensive GitHub use as their learning evolves beyond CS50. Says Malan:

One goal was to have students graduate, so to speak, from the class actually having a GitHub account. And even though they don't keep their work in public portfolios for the course, the hope is that they'll have at least enough understanding of GitHub that they can use it after the term ends for personal projects.

Course outline for CS50

Student workflow for submit50

CS50 uses the structure of one branch per problem, and students engage Git and GitHub from the command line.

First, they run a command in their directory on a Linux system with a folder they wish to submit to CS50’s servers. The student then runs submit50 foo where foo is the unique identifier for that assignment.

submit50 models how Git and GitHub work while abstracting away some of the complexity:

Behind the scenes we show them the command so that through a bit of osmosis, they can infer what's actually going on.

We clone their repo, which lives in our submit50 organization. So we have full administrative rights, and students have push and pull privileges only.

The submit50 script clones that repo into a temporary directory. We do the equivalent of rm -rf to blow away whatever is currently in there, and then git-add the entire contents of their current working directory into that repo, and then tag it with a tag that corresponds to the problem's name, and then push it to the server.

Project-based assignments, real-life applications

An example assignment is “C$50 Finance” where students build an application to simulate stock trades using Python with Flask, HTML, CSS and SQL.

Students create tables with user accounts, who can then buy and sell stocks. The application queries Yahoo Finance for stock quotes, almost in real time.

Malan is delighted to see the different personal touches students add to their projects, both functional and aesthetic.

It's a fun opportunity to introduce students to even the aesthetics of web design. Invariably the first thing students do is customize the aesthetics of the site, and then certainly there are differences in features, and we're fine with that. The assignment requires ultimately that they add a personal touch, so any feature that's not been enumerated by us they're welcome to do so long as it's of reasonable scope. So we'll get different outputs from that as well.

Rituals of success

All students exhibit their final projects an end-of-semester “CS50 Fair.” About 2,200 people attend to see the student demos.

Malan designs the event as a kind of celebration, a capstone ritual where students can show people what they’ve made:

It's a fun way to delight in how much you've finished, particularly if new to programming just months prior. And it perhaps creates a bit of social pressure too. You know you're going to be showing this not just to your Teaching Fellow, but to your classmates, and you want to be proud of it. And so, hopefully, that incentivizes all the more of a strong finish.

Computer science and tech news = CS50 Live

Pushing beyond the boundaries of the traditional classroom, Malan connects the course materials with the news in a kind of “Daily Show” for technology, called “CS50 Live.”

Malan and the crew of Teaching Fellows take up current events, like Apple’s implementation of OpenSSL with a bug in it, and dig into the code on the show.

This is a post in our “Teacher Spotlight” series, where we share the different ways teachers use GitHub in their classrooms. Check out the other posts:

Join this week’s discussion in the community forum: How to automatically gather or collect assignments?

How to run a Google Summer of Code project on GitHub

Google provides some guidance on how to effectively run a Google Summer of Code project but it's not tailored specifically to GitHub's workflow. To set clear expectations for mentors and students here's our ideas on how to successfully participate in Google Summer of Code as a mentor or organization administrator.

The application process

Document project ideas

Make a dedicated file or repository for documenting project ideas and discuss them in issues. The ideas should be things that are going to be useful to your project, would take a maintainer a week or two to complete and you think should take a student between a month and a month and a half to complete. You can populate these from help wanted-labeled issues in your repository. They should be brief enough to stimulate discussion on their implementation but not detailed enough for students to be able to copy-paste any part into their proposal.

For example, the Homebrew project has a repository for these ideas (updated for GSoC 2017).

Strongly encourage students to adopt one of your ideas rather than their own. You have a much better idea than they do on what will be useful, achievable, and mergeable.

Require a merged pull request to your project

Rather than angsting over student technical interviews or their proposals documents you should make your decision primarily on which students (if any) to accept based on a trial of the work you expect from them in the summer: a pull request to your project's repository. Google expects students to get involved in communities so requiring e.g. a one line change in a pull request is more time efficient than any other metric.

In general any established GitHub open source repository should have an easy way for new, aspiring contributors to submit a useful pull request. In Homebrew's case they have a brew audit linting tool where some lints are deliberately left unfixed to give newcomers an opportunity for an easy first pull request.

For example, the Homebrew project's process is documented in their README.

You should not help students any more than any new contributor or provide any more guidance than what's already documented in your project. If they ask for help, point them to the instructions (and consider improving them). If they cannot figure out what other contributors can: they are unfortunately not good candidates for GSoC which requires them to be self-motivated, driven and able to learn independently over the summer.

Provide regular review to student pull requests before the application deadline. Make it clear to the student that the pull request must go through the review process and get merged before you can accept their application. They're in a rush, but you shouldn't be. In respect of time, students shouldn't rush last minute to hit a deadline.

The summer

Favor small pull requests over large ones

This is a good principle in general but not the typical mindset for students who typically do work for a single output that's handed in. Encourage them to split their work up into multiple, regular pull requests over the summer so their pull requests can be more easily reviewed and merged.

For example, see @AnastasiaSulyagina's pull request to remove some duplicated exceptions as part of Homebrew's 2016 GSoC. This was a small change review and a merge followed quickly.

Maintain normal flow

Most of your interactions with your student should look like your interactions with other maintainers and contributors on your project. For example, if you talk with other maintainers on Slack, invite your student and encourage them to ask questions when they have them. If you can talk about things in issue comments and pull request reviews: do that instead of video calls or other private methods of communication so that other maintainers can help provide review and feedback.

Brief, regular check-ins

Have a meeting that you both stick to every week (that neither of you are on vacation) on text (i.e. IM), audio or video chat. Defer to the student's preferences on IM vs. audio/video as they may feel more comfortable communicating over text if English isn't their first language. This should be your chance to see what progress there has been if there's been no public activity. That said, a week with no commits, issue comments, or PR comments is a sign of major concern that you should raise with the student.

Strict failure requirements

As mentioned previously: you should not accept students who have not made a trivial pull-request to your project. Similarly, the focus of the summer should be around pull-requests too. If the student does not have a significant, non-trivial pull request opened by their mid-term: they should fail. If the student does not have a significant, non-trivial pull request merged by the end of the program: they should fail. Again, splitting the work up into multiple pull requests over the summer is vastly preferable to opening pull requests at the last minute.

Like many things in life: strict, no-compromise boundaries may sound harsh but end up being kinder to the student. You can communicate these expectations at the beginning of the program and then they don't need to worry about whether they will pass or fail. This is also a life lesson: many deadlines after graduation are not negotiable and it's better to fail at GSoC than many other things in life.

That seems quite strict?

It does, yes. The requirements above may mean that you're not able to get any students who are good enough for your project or that you need to fail students. This is unfortunate but it's ultimately better for students and much better than having a bad GSoC experience.

For point of comparison while following the above system for the last two years the Homebrew project has always had more good students than mentors available for them, never failed any students, had the majority of students ship major features our users have been happy with and, best of all, had a minority of students become and stay Homebrew maintainers.

Now that you know how to effectively run a Google Summer of Code project on GitHub consider applying as a GSoC organisation before the February 9, 2017 at 17:00 (GMT) deadline and have a great summer!

GitHub Classroom for AP Computer Science at Naperville North High School

We released GitHub Classroom in fall of 2015 to make it easier for teachers to distribute code and collect assignments on GitHub. In the last year, we've seen it enter the classrooms of thousands of teachers. We're delighted that it's helping students learn STEM subjects and even more excited to share the processes, tips, and tricks educators have built around it.

To kick off a series about educators and classroom practices, we'd like to introduce you to Geoff Schmit, a former engineer for National Instruments. In his tenth year of teaching at Naperville North High School, Geoff seeks to prepare students with the mindset of a creative, ethical engineer who uses real-world tools:

I had a background in source control which I brought with me from my life as a software engineer. I think students should learn about source control before they leave this class. They should have written unit tests before they leave this class. And they should read articles about technology in society and ethics before they leave this class.

He kickstarts his semester with pre-filled repositories—sample code and libraries in GitHub Classroom. Students dive straight in, without the tool getting in the way:

On the first days of school I want them doing turtle graphics in BlueJ. I don't want to worry about setting up the environment and everything. So I'm able to pre-package everything, so they can double-click on it and type some code in, and we'll work.

This is his first year using GitHub Classroom to organize his assignments and gently introduces students to GitHub.

Using Classroom, students click on a single link to create and manage their repositories:

So rather than them having to worry about forking, cloning, and that stuff, they just click on the link to accept the assignment.

With Github Classroom things are so much smoother because it copies the whole assignment into a private repository, which is nice.

Distribute assignments with one link

To submit their assignment, students commit to the master branch of their own repositories, then pass that link to Geoff’s Learning Management System (LMS), Canvas.

To grade their the project, Geoff downloads the code through the GitHub desktop client, runs it, and assesses the lab.

I have the link right there to GitHub, and I click on it, and I download it, go through all their code, run it, whatever, and just go right on to the next one. So it's super fast to take a look at their code and run it, which is great. It's been really easy. It's worked really well.

Creative assignments

Dr. Mitchell Resnick, creator and educator of Scratch, refers to learning experiences with “low floors, wide walls:” activities that are easy to begin, but enable a creative flow that keeps learners engaged past the requirements.

Geoff’s labs aim to spark this kind of engagement in his students. The Cityscape Lab, one of four over the semester, offers few concrete specifications: create three classes and animate your Cityscape in some way.

Cityscape Lab from Schmit’s course

So, that's the low floor and for some students, that's going to be a stretch and they're going to work really hard to do that.

But then for others, it's like, "Well, you could do more." We haven't done loops or anything yet so I say, can you figure out how to do windows, other than having to draw all 100 of them by hand? or *can you figure out basic looping structures? 

And I've had submissions like a student who downloaded constellation star data so the stars in the sky actually matched reality. I'm sure she spent hours and hours outside of class working on that but she was really excited about it, whereas other students just got their buildings done, and that's fine.

What I have been surprised about, because I was worried about it at first, is that when students meet the requirements they don't stop.

Top Classroom hacks

Geoff has several AP Computer Science courses a day. When he’s demonstrating to his class and projecting code snippets or examples, he uses one branch per class period.

So when Period Four starts on Tuesday, Geoff picks up from yesterday’s branch:

Every day I update Canvas with a link to the branch of each class period. If a student is absent, they know where to find everything we did together as a class yesterday. And that's been really great.

Take risks, trust each other

Geoff only grades exams and a summative lab at the end four units. All the other projects, daily hands-on activities, and everything else, is all practice.

By putting projects front-and-center instead of grades, Geoff says students are more open to learning experiences that might put them in more vulnerable positions, like sharing work and pair programming.

Students say to themselves, "I can take risks. I'm not being graded on this. I'm not worried about my partner not doing as well as me, because we're just practicing." That trust goes a long way towards helping them accept different kinds of activities.

This is a post in our “Teacher Spotlight” series, where we share the different ways teachers use GitHub in their classrooms. Check out the other posts:

CARTO adds data insights to the Student Developer Pack

CARTO is the newest addition to the GitHub Student Developer Pack.

CARTO joins the Student Developer Pack

CARTO is a powerful open platform for discovering and predicting key insights underlying the world's location data. It's a suite of geospatial tools, services, and APIs for discovering and predicting the key insights from your location data in your applications. You'll be able to do powerful analysis of your data.

With CARTO you get:

  • CARTO Builder, a web-based drag-and-drop analysis tool for users to discover and predict key insights from location data.
  • CARTO Engine, a one-stop shop of geospatial tools, services, and APIs to discover and make predictions with your location data.
  • A Mobile SDK that lets you develop custom applications with maps on any mobile platform—Android, iOS, and Windows Mobile 10.
  • Location data services that let you obtain maps and services on native applications, using them on the web with open source JavaScript or third-party libraries.
  • Data Observatory services so you can turn your data or address locations into comprehensive reports about the characteristics of the local population.

Members of the pack get:

  • 350MB Database Storage
  • Synced Tables
  • $5 worth of LDS credit per month
  • 10K tweets per month
  • 100K mapviews per month
  • Free account upgrades with increased database storage
  • Real-time data
  • Location data service credits
  • Premium features

The Student Developer Pack gives students free access to the best developer tools from different technology companies like Datadog, GitKraken, Travis CI, and Unreal Engine.

Students, get mapping now with your pack.

Flatiron School joins the GitHub Student Developer Pack

Flatiron School has joined the Student Developer Pack to offer students one free month of their Community-Powered Bootcamp, a flexible online course in web development.

Flatiron School joins the Student Developer Pack

The Community-Powered Bootcamp is a self-paced subscription program for beginners. You'll learn online using the same course of study as the Web Developer Program—a comprehensive curriculum tailored to job seekers. In a month, you can pick up a few in-demand skills and work with a community of other learners to start reaching your goals, whether they are technical literacy, a new programming language, or a new career.

The details

  • Get the first month of tuition free
  • Start 800+ hours of rigorous web development coursework
  • Take on topics like HTML, CSS, JavaScript, Node.JS, React, and Ruby on Rails
  • Learn online and at your own pace with a curated community of students
  • Build a portfolio
  • Get help when you need it, 24/7

After one month, you can sign up for a monthly subscription of $149 USD.

The Student Developer Pack gives students free access to the best developer tools from different technology companies like Datadog, GitKraken, Travis CI, and Unreal Engine. Sign up for the pack, and start learning.

GitKraken joins the Student Developer Pack

GitKraken is now part of the Student Developer Pack. Students can manage Git projects in a faster, more user-friendly way with GitKraken's Git GUI for Windows, Mac, and Linux.

GitKraken joins the Student Developer Pack

GitKraken is a cross-platform GUI for Git that makes Git commands more intuitive. The interface equips you with a visual understanding of branching, merging and your commit history. GitKraken works directly with your repositories with no dependencies—you don’t even need to install Git on your system. You’ll also get a built-in merge tool with syntax highlighting as well as one-click undo and redo for when you make mistakes. Other features of GitKraken are:

  • Drag and drop to merge, rebase, reset, push
  • Resizable, easy-to-understand commit graph
  • File history and blame
  • View image diffs in app
  • Fuzzy finder and command palette
  • Submodules and Gitflow support
  • Easily clone, add remotes, and open pull requests in app
  • Keyboard shortcuts
  • Dark and light color themes
  • GitHub integration

Members of the pack get GitKraken Pro free for one year. With GitKraken Pro, Student Developer Pack members will get all the features of GitKraken plus:

  • The ability to resolve merge conflicts in the app
  • Multiple profiles for work and personal use
  • Support for GitHub Enterprise

Students can get free access to professional developer tools from companies like Datadog, Travis CI, and Unreal Engine. The Student Developer Pack lets you learn, experiment, and build software with the tools developers use at work every day without worrying about cost.

Students, get a Git GUI now with your pack.