forked from mvl22/trac2github
-
Notifications
You must be signed in to change notification settings - Fork 0
/
config.php.sample
102 lines (80 loc) · 3.34 KB
/
config.php.sample
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
<?php
// Edit configuration below
$project = 'Organization or User name';
$repo = 'Repository name';
$username = $default_username = 'Put your github username here';
$oauth_token = $default_oauth_token = false; // Get a token from https://help.github.com/articles/creating-an-oauth-token-for-command-line-use
// or, less securely:
$password = $default_password = false;
// All users must be valid github logins!
$users_list = array(
'TracUsermame' => 'GithubUsername',
'Trustmaster' => 'trustmaster',
'John.Doe' => 'johndoe'
);
// Map of github user => OAuth tokens, as created here:
// https://help.github.com/articles/creating-an-oauth-token-for-command-line-use
// i.e. ask each user to do this and then give you the token:
// curl -u 'the-username' -d '{"scopes":["repo"],"note":"Trac conversion"}' https://api.github.com/authorizations
$github_users_oauth_tokens = array (
// 'github username' => 'github oauth token',
);
// Map of github user => password to create issues and comments as in trac. Leave empty to use github default user specified above from $default_username and $default_password var
// Using the oauth token method above is more secure and preferable.
$github_users_passwords = array (
// 'github username' => 'github password',
);
// array with svn revision as keys and related git revision as value
$convert_revision = array();
// alternative to $convert_revision: php file with $covert_revision array (useful because it can be a very big)
$convert_revision_file = "/path/to/file/revision-svn2git.php";
// specify database type. should be either MYSQL, SQLITE, or POSTGRES
$database_type = POSTGRES;
$db_host = 'Trac database host';
$db_port = 'Trac database port';
$db_name = 'Trac database name';
$db_user = 'Trac database user';
$db_password = 'Trac database password';
// For SQLite only, set the path to the database here. For other
// database types, this field is ignored.
$db_path = false;
// Do not convert milestones at this run
$skip_milestones = false;
// Do not convert labels at this run
$skip_labels = false;
// Change this if you want to customize your label colors:
$label_color = array (
'type' => 'cccccc',
'component' => '0000aa',
'priority' => 'aa8888',
'resolution' => '55ff55',
);
// 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 = false;
$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_labels = '/tmp/trac_labels.list';
$save_tickets = '/tmp/trac_tickets.list';
// Set this to true if you want to see the JSON output sent to GitHub
$verbose = false;
// Rate limiting as requests per hour; see http://developer.github.com/v3/#rate-limiting
// Higher than 5000 is not recommended as this seems to result in entries appearing slightly out of order
$rateLimit = 5000;
// Whether to remove e-mail addresses
$removeEmailAddresses = false;
// Text replacements within tickets
$textReplacements = array (
// 'search1' => 'replace1',
// 'search2' => 'replace2',
);
// Uncomment to refresh cache
// @unlink($save_milestones);
// @unlink($save_labels);
// @unlink($save_tickets);
?>