Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Move configuration from trac2github.php to external files

  • Loading branch information...
commit d7ff9e2cf2bcd304eca08bd34921b54984d57054 1 parent 3bc3043
@danielbeardsley danielbeardsley authored
Showing with 16 additions and 47 deletions.
  1. +13 −0 config.php.sample
  2. +3 −47 trac2github.php
View
13 config.php.sample
@@ -0,0 +1,13 @@
+<?php
+
+/**
+ * Sample configuration file, copy this to config.php and edit
+ */
+
+$repo = 'user/repo';
+
+Trac::$host = 'Trac MySQL host';
+Trac::$user = 'Trac MySQL user';
+Trac::$password = 'Trac MySQL password';
+Trac::$db = 'Trac MySQL database name';
+
View
50 trac2github.php
@@ -1,54 +1,10 @@
<?php
-/**
- * @package trac2github
- * @version 1.0.1
- * @author Vladimir Sibirov
- * @copyright (c) Vladimir Sibirov 2011
- * @license BSD
- */
require("github.php");
+require("trac.php");
+require("config.php");
+require("ticket.php");
-// Edit configuration below
-
-require("credentials.php");
-$project = 'Organization or User name';
-$repo = 'Repository name';
-
-// All users must be valid github logins!
-$users_list = array(
- 'TracUsermame' => 'GithubUsername',
- 'Trustmaster' => 'trustmaster',
- 'John.Done' => 'johndoe'
-);
-
-$mysqlhost_trac = 'Trac MySQL host';
-$mysqluser_trac = 'Trac MySQL user';
-$mysqlpassword_trac = 'Trac MySQL password';
-$mysqldb_trac = 'Trac MySQL database name';
-
-// Do not convert milestones at this run
-$skip_milestones = false;
-
-// Do not convert tickets
-$skip_tickets = false;
-$ticket_offset = 0; // Start at this offset if limit > 0
-$ticket_limit = 0; // Max tickets per run if > 0
-
-// Do not convert comments
-$skip_comments = true;
-$comments_offset = 0; // Start at this offset if limit > 0
-$comments_limit = 0; // Max comments per run if > 0
-
-// Paths to milestone/ticket cache if you run it multiple times with skip/offset
-$save_milestones = '/tmp/trac_milestones.list';
-$save_tickets = '/tmp/trac_tickets.list';
-
-// Uncomment to refresh cache
-// @unlink($save_milestones);
-// @unlink($save_tickets);
-
-// DO NOT EDIT BELOW
error_reporting(E_ALL ^ E_NOTICE);
ini_set('display_errors', 1);
Please sign in to comment.
Something went wrong with that request. Please try again.