Git instructions and workflows

Events happening in the community are now at Drupal community events on www.drupal.org.
eliza411's picture

I’ve been working on Drupal.org documentation and Project Git Instructions (the contextual cut-and-paste directions provided for each project) not because I’m particularly the best person for the job but because as project manager for the migration, I have a vested interest in the community’s successful transition and, more importantly, I’ve been the least busy person who also has access to the team. It’s hard to document what doesn’t exist, and the project has been moving at breakneck speed to be ready for Chicago DrupalCon.

With less than 72 hours to deployment, we’re getting a much wider range of testers and more varied feedback, highlighting Git’s extreme flexibility and the myriad ways of accomplishing things. In practice, this means that every single Git command recommended can be debated and of course, will be, but in the end no single successful path can be recommended to all the people interacting with Git on Drupal.org.

What the Git Migration Team and the folks who work on Project Git Instructions are trying to provide are paths which if followed explicitly, are most likely to lead the greatest number of users to succeed while generating the fewest support requests. It is not our goal, nor should it be, to teach Git. While every developer, patch contributor, and site builder is encouraged to learn as much or as little Git as they need and desire, we strive to create and recommend ways of using Git to support vibrant, effective collaboration on Drupal.org.

The transition for our community is enormous, and toward that end, Project Git Instructions will be continue to undergo substantial transformation until the end of the day tomorrow, Wednesday, February 23. Its target audience will be, at least for now, exclusively code contributors. People deploying sites with Git are no less important in the overall scheme of things, but it’s my stance that we care for them best by caring for the contributors first. I also think that people deploying sites via Git can be well-cared for in the Drupal.org docs. Moreoever, we have a packaging system that generates tarballs, which is still the primary mechanism by which we expect site deployers to do their work - and that workflow is unchanged.

Certainly making adjustments for plain brokenness will be accommodated, but philosophically, I believe the community is best-served by making a coordinated effort, allowing the entire community and not just early adopters to interact with it, scrutinizing the process, taking full advantage of the face-to-face opportunities at DrupalCon, and doing a comprehensive review of our recommendations in mid-to-late March.

Git instructions and the workflows won't be set in stone tomorrow or ever. They'll be able to react over time, but with the key objectives of simplicity, user success, and minimized support, coupled with not intending to teach people Git or to prescribe their behavior. I’m posting this primarily so that as all the valuable, conflicting, and honestly-appreciated suggestions for improvements come in, people have some idea what’s guiding decision-making and what the time ine for engaging conversations about best practices looks like.

Comments

+1: I'm not going to pretend

mark trapp's picture

+1: I'm not going to pretend to be versed in the background of these issues, so I can only speak as random contributor 212019. But the CVS instructions targeted only towards contributors seemed to work.

To give my thoughts on what needs to change with Git Instructions, in order of urgency:

  1. Things that lead to bad or unexpected things should be fixed or removed: checking out a remote branch, checking out a new branch, etc. Since those can really throw people for a loop, ideally those should be fixed before the migration.
  2. As best as possible, the instructions should mimic all the actions you could take in the CVS instructions (they seem to do that now, but there's probably an opportunity to bikeshed). Nice to have before migration, but this could take some time and what's there now looks fine.
  3. Any potential "gotchas" (for contributors) could use a passing mention and a link to the relevant handbook page. There are potentially an infinite number of these, but there's definitely a top 5 or top 3 list of ones that a git newcomer will run into (detached HEAD, stashing changes, etc.). Again, nice to have, not as important as removing breaking things or CVS instruction replication. Ideally, the instructions page shouldn't steer you wrong if you follow the instructions exactly.

I'm not sure this is the best

joachim's picture

I'm not sure this is the best place to discuss this....

But with regard to how to handle branches, a common problem with CVS that we could overcome now is this scenario:

  1. Maintainer releases module 1.0
  2. Maintainer does more work, makes commits of big changes to the module that need testing in -dev.
  3. A simple bug is found in the module and the fix is committed
  4. The module is now stuck with a buggy 1.0, and a -dev that needs more testing before a 1.1 release can be made, and users have to go and find the patch and apply it if they want to run the stable version on their site.

This would be handled by having a hotfixes branch alongside the development branch together forming what we used to think of as a CVS branch.

I'm taking inspiration from http://nvie.com/posts/a-successful-git-branching-model/ -- not that I pretend to completely understand it... :)

Drupal.org Git Team

Group organizers

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: