2

Some fellow students and I are trying to introduce other students to git/Github and holding seminars has never really worked to get students excited and to start taking advantage of the tool and service. This year we want to try and work it into the course by having students use git to submit their projects for grading.

The problem is; we have yet to come up with a proper work flow to do this. Ideally all this could be accomplished via Github. Our school has Github Enterprise (read unlimited public/private repos) so we have some room to play around. I'm not sure how much customization we can do, I'm not really sure what all Github Enterprise provides in that are either.

My first workflow was as follows.

  • Teaching Assistant posted a repo with starting code and the project description/assignment
  • Students fork the repo to a private repository (I have a feeling this is not possible)
  • Students work on their project individually
  • When a student is ready to submit their project, they submit a Pull Request back to the Teaching Assistant.

I'm pretty sure there are a few flaws in this, one being that we want to try and keep the students work private. Forking to a private repo may not be possible, and the pull request I'm sure would not work.

I'm curious if someone has done something similar or has any ideas. I'm also willing to setup a separate server. My thinking here would be that students could use Github (private repos) to centralize their code and get familiar with Github by forking the project and working from there. When it comes to submitting their project for grading they would then push the project to a separate server. I'm not entirely sure how this would work, but I figure there would be some way to allow for accepting push request and pushing them into different branches via a hook.

The idea is that having students work with git/github for the project might get them to start using version control in general for actually working on their project. Granted there are going to be the students that won't commit anything till they are finished anyways. This is more about exposing students to the technology.

travis
  • 8,055
  • 1
  • 17
  • 19
  • 2
    I do not see what using github adds for what you presumably want to teach (e.g. using modern version control). Teach them *git* instead of *github* and let them email a patch series (e.g. even with `git send-email` if you give them a howto at the start). That way all the problems with private/non-private repos just go away since their clones are in their control and not tied to some predetermined workflow. – Benjamin Bannier Jul 12 '13 at 18:12
  • https://classroom.github.com/ seems to allow that, and you can apply for free private repos. – tamberg Sep 09 '18 at 08:57

1 Answers1

2

Well, this isn't really a question that fits well with SO.

Nevertheless, here are some of my personal thoughts:

As was pointed out in the comments to your question, using Github [Enterprise] for this might be somewhat over the top when it comes to teaching Git. While you will need some kind of server to allow the students to get and hand in their data, Github is very focused on its web interface. Even if using Github for collaboration is part of your class, you should put considerable effort in having the students learn Git first.

I am not 100% sure about how forking and permissions behave in GHE, but it usually goes like this: A public repository can only be forked to a public repo; if the forking user wants to change the repo's status to private (if GHE even allows that), it will remove the "fork" connection (thereby making Pull Requests impossible). If a user clones a private repository, it will automatically be private, but as far as I know, it will retain the permission list of the original repo. That means: if you give all your students access to the private repo to clone it, all of their forks will (by default) also have those permissions, and once again their code will not be private (enough).

Thirdly, I don't think PRs are a good way to have students hand in their assignments. PRs are intended to propagate code/changes into the upstream repo, but that would mix up the code of all students. Instead, have the students tag the commit which they want to submit for grading, and then notify you about the tag somewhere (posting an issue on Github, sending an email, whatever). Expanding on this, you could use a server solution like Gitolite, in which you can forbid users to delete tags -- thus, once submitted, students cannot change or take back their submissions.

And finally: depending on the structure of the assignments during this class, I don't know if using a single repo/fork structure is a good way to learn project management. Let's assume assignments work like at my university: every one or two weeks, the students get assignments, which are pretty much self-contained. Following the standard one-repo-per-project convention, that would be somewhere between one to four repos per student per week. Handling this with fork-networks creates considerable overhead for your teaching assistant (at least on Github, when doing it by hand; using the Github API or a more customizable solution like Gitolite, this could be scripted).
If, on the other hand, you have a single (or maybe two) projects on which a student works during the whole class, submitting it for review regularly (or once at the end), using a fork-network or something similar is much more feasible. In that way the idea of using tags will also teach the students the convention of using tags to mark important milestones (which, in some contexts, might be releases).

That's all from me for now. I certainly advise you to use a more interactive medium suited better to a discussion like this. SO is intended for questions which have a relatively unambiguous answer. You could stop by the IRC channel #git on irc.freenode.com or try the SO chat; or maybe a discussion forum would also work well.

Nevik Rehnel
  • 49,633
  • 6
  • 60
  • 50