How to maintain your own branch of Drupal core Neil Drumm 5.x branch maintainer
I am not actually going to tell you about branching Drupal. Do not do that.
This is about Drupal 5.x.
“Neil has quite a knack for detecting attempts to get cruft into Drupal.” “Neil has been the co-founder and maintainer of CivicSpace, the first Drupal distribution.” —  Dries Buytaert http://buytaert.net/neil-drumm
One rule: Do not commit features from coworkers
 
 
 
 
Patch reviews Collected 16/Sep/2007
Commits per week
Top reviewers  318 total Collected 16/Sep/2007 Number of issues changed from needs review or ready to commit
Top patch writers  830 total Collected 16/Sep/2007 Number of issues posting an attachment follow up
How to review a patch
Code style if (arg(0) == 'node' && arg(1) == 'add' && $type = arg(2)) { $type = node_get_types('type', str_replace('-', '_', arg(2))); -  return '<p>'. filter_xss_admin($type->help) .'</p>'; +  +  if ( $help = filter_xss_admin($type->help) ) { +  return '<p>'. $help .'</p>'; +  } } } http://drupal.org/node/112140
Functionality +  if ($return_path && !ini_get('safe_mode')) { +  return mail( +  $to, +  mime_header_encode($subject), +  str_replace(&quot;\r&quot;, '', $body), +  join(&quot;\n&quot;, $mimeheaders), +  '-f'. $return_path +  ); +  } http://drupal.org/node/131737
Usability // Output a list of queries executed if (!empty($_SESSION['update_results'])) { $output .= '<div id=&quot;update-results&quot;>'; -  $output .= '<h2>The following queries were executed</h2>'; +  $output .= '<h2> The following status messages were returned </h2>'; foreach ($_SESSION['update_results'] as $module => $updates) { $output .= '<h3>'. $module .' module</h3>'; http://drupal.org/node/167610
Scalability $sql = 'SELECT DISTINCT u.uid, u.name, u.status, u.created, u.access FROM {users} u LEFT JOIN {users_roles} ur ON u.uid = ur.uid '. $filter['join'] .' WHERE u.uid != 0 '. $filter['where']; $sql .= tablesort_sql($header); -  $result = pager_query($sql, 50, 0, NULL, $filter['args']); +  $count_sql =  'SELECT COUNT(DISTINCT(u.uid)) FROM {users} u LEFT JOIN {users_roles} ur ON u.uid = ur.uid '. $filter['join'] .' WHERE u.uid != 0 '. $filter['where'] ; +  $count_sql .= tablesort_sql($header); +  +  $result = pager_query($sql, 50, 0, $count_sql, $filter['args']); $form['options'] = array( '#type' => 'fieldset', http://drupal.org/node/137754
Security $session_name = $cookie_domain; } else { +  // If the site is using session.cookie_secure, use $base_url as +  // session name. +  if (ini_get('session.cookie_secure')) { +  $session_name = $base_url; +  } // Otherwise use $base_url as session name, without the protocol // to use the same session identifiers across http and https. -  list( , $session_name) = explode('://', $base_url, 2); +  else { +  list( , $session_name) = explode('://', $base_url, 2); +  } // We try to set the cookie domain to the hostname. // We escape the hostname because it can be modified by a visitor. if (!empty($_SERVER['HTTP_HOST'])) { http://drupal.org/node/170310
How to review a patch Code style Is it readable? Functionality Does it work? Usability Does it make sense? Scalability Will it scale? Security Is it secure? More at http://drupal.org/patch/review
Releases
5.0
5.1
5.2
What I learned
It is impossible to fix everything
There will be another release
Someone will find the right solution for every issue
 

Maintaining your own branch of Drupal core

  • 1.
    How to maintainyour own branch of Drupal core Neil Drumm 5.x branch maintainer
  • 2.
    I am notactually going to tell you about branching Drupal. Do not do that.
  • 3.
    This is aboutDrupal 5.x.
  • 4.
    “Neil has quitea knack for detecting attempts to get cruft into Drupal.” “Neil has been the co-founder and maintainer of CivicSpace, the first Drupal distribution.” — Dries Buytaert http://buytaert.net/neil-drumm
  • 5.
    One rule: Donot commit features from coworkers
  • 6.
  • 7.
  • 8.
  • 9.
  • 10.
  • 11.
  • 12.
    Top reviewers 318 total Collected 16/Sep/2007 Number of issues changed from needs review or ready to commit
  • 13.
    Top patch writers 830 total Collected 16/Sep/2007 Number of issues posting an attachment follow up
  • 14.
  • 15.
    Code style if(arg(0) == 'node' && arg(1) == 'add' && $type = arg(2)) { $type = node_get_types('type', str_replace('-', '_', arg(2))); - return '<p>'. filter_xss_admin($type->help) .'</p>'; + + if ( $help = filter_xss_admin($type->help) ) { + return '<p>'. $help .'</p>'; + } } } http://drupal.org/node/112140
  • 16.
    Functionality + if ($return_path && !ini_get('safe_mode')) { + return mail( + $to, + mime_header_encode($subject), + str_replace(&quot;\r&quot;, '', $body), + join(&quot;\n&quot;, $mimeheaders), + '-f'. $return_path + ); + } http://drupal.org/node/131737
  • 17.
    Usability // Outputa list of queries executed if (!empty($_SESSION['update_results'])) { $output .= '<div id=&quot;update-results&quot;>'; - $output .= '<h2>The following queries were executed</h2>'; + $output .= '<h2> The following status messages were returned </h2>'; foreach ($_SESSION['update_results'] as $module => $updates) { $output .= '<h3>'. $module .' module</h3>'; http://drupal.org/node/167610
  • 18.
    Scalability $sql ='SELECT DISTINCT u.uid, u.name, u.status, u.created, u.access FROM {users} u LEFT JOIN {users_roles} ur ON u.uid = ur.uid '. $filter['join'] .' WHERE u.uid != 0 '. $filter['where']; $sql .= tablesort_sql($header); - $result = pager_query($sql, 50, 0, NULL, $filter['args']); + $count_sql = 'SELECT COUNT(DISTINCT(u.uid)) FROM {users} u LEFT JOIN {users_roles} ur ON u.uid = ur.uid '. $filter['join'] .' WHERE u.uid != 0 '. $filter['where'] ; + $count_sql .= tablesort_sql($header); + + $result = pager_query($sql, 50, 0, $count_sql, $filter['args']); $form['options'] = array( '#type' => 'fieldset', http://drupal.org/node/137754
  • 19.
    Security $session_name =$cookie_domain; } else { + // If the site is using session.cookie_secure, use $base_url as + // session name. + if (ini_get('session.cookie_secure')) { + $session_name = $base_url; + } // Otherwise use $base_url as session name, without the protocol // to use the same session identifiers across http and https. - list( , $session_name) = explode('://', $base_url, 2); + else { + list( , $session_name) = explode('://', $base_url, 2); + } // We try to set the cookie domain to the hostname. // We escape the hostname because it can be modified by a visitor. if (!empty($_SERVER['HTTP_HOST'])) { http://drupal.org/node/170310
  • 20.
    How to reviewa patch Code style Is it readable? Functionality Does it work? Usability Does it make sense? Scalability Will it scale? Security Is it secure? More at http://drupal.org/patch/review
  • 21.
  • 22.
  • 23.
  • 24.
  • 25.
  • 26.
    It is impossibleto fix everything
  • 27.
    There will beanother release
  • 28.
    Someone will findthe right solution for every issue
  • 29.