[ Index ]

PHP Cross Reference of Eventum

title

Body

[close]

/ -> scm_ping.php (source)

   1  <?php
   2  /* vim: set expandtab tabstop=4 shiftwidth=4 encoding=utf-8: */
   3  // +----------------------------------------------------------------------+
   4  // | Eventum - Issue Tracking System                                      |
   5  // +----------------------------------------------------------------------+
   6  // | Copyright (c) 2003, 2004, 2005, 2006, 2007 MySQL AB                  |
   7  // |                                                                      |
   8  // | This program is free software; you can redistribute it and/or modify |
   9  // | it under the terms of the GNU General Public License as published by |
  10  // | the Free Software Foundation; either version 2 of the License, or    |
  11  // | (at your option) any later version.                                  |
  12  // |                                                                      |
  13  // | This program is distributed in the hope that it will be useful,      |
  14  // | but WITHOUT ANY WARRANTY; without even the implied warranty of       |
  15  // | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        |
  16  // | GNU General Public License for more details.                         |
  17  // |                                                                      |
  18  // | You should have received a copy of the GNU General Public License    |
  19  // | along with this program; if not, write to:                           |
  20  // |                                                                      |
  21  // | Free Software Foundation, Inc.                                       |
  22  // | 59 Temple Place - Suite 330                                          |
  23  // | Boston, MA 02111-1307, USA.                                          |
  24  // +----------------------------------------------------------------------+
  25  // | Authors: João Prado Maia <jpm@mysql.com>                             |
  26  // +----------------------------------------------------------------------+
  27  //
  28  // @(#) $Id: scm_ping.php 3206 2007-01-24 20:24:35Z glen $
  29  
  30  // shortcut to exit out when no issue id-s are passed in request
  31  // as this script is always called by CVS but we handle only ones which can be
  32  // associated with issues.
  33  if (empty($_GET['issue'])) {
  34      exit;
  35  }
  36  
  37  require_once(dirname(__FILE__) . "/init.php");
  38  require_once (APP_INC_PATH . "class.misc.php");
  39  require_once (APP_INC_PATH . "class.scm.php");
  40  require_once (APP_INC_PATH . "class.workflow.php");
  41  require_once (APP_INC_PATH . "db_access.php");
  42  
  43  foreach ($_GET['issue'] as $issue_id) {
  44      $files = array();
  45      for ($y = 0; $y < count($_GET['files']); $y++) {
  46          SCM::logCheckin($issue_id, $y);
  47          $files[] = array(
  48              'file' => $_GET['files'][$y],
  49              'old_version' => $_GET['old_versions'][$y],
  50              'new_version' => $_GET['new_versions'][$y],
  51          );
  52      }
  53  
  54      $prj_id = Issue::getProjectID($issue_id);
  55      $module = $_GET['module'];
  56      $username = $_GET['username'];
  57      $commit_msg = $_GET['commit_msg'];
  58  
  59      Workflow::handleSCMCheckins($prj_id, $issue_id, $module, $files, $username, $commit_msg);
  60  }


Generated: Wed Dec 19 21:21:33 2007 Cross-referenced by PHPXref 0.7