Simple external changes syncer and conflict resolution. More...
Public Member Functions | |
__construct (MessageGroup $group) | |
setProgressCallback ($callback) | |
getTimestampsFromSvn ($file) | |
Fetch last changed timestamp for a versioned file for conflict resolution. | |
getTimestampsFromGit ($file) | |
Fetch last changed timestamp for a versioned file for conflict resolution. | |
getTimestampsFromFs ($file) | |
Fetch last changed timestamp for any file for conflict resolution. | |
checkConflicts ($code, $startTs=false, $endTs=false, $changeTs=false) | |
Do some conflict resolution for translations. | |
color ($color, $text) | |
Colors text for shell output. | |
getLastGoodChange ($title, $startTs=false) | |
Try to identify when the translation was last changed in the wiki. | |
import ($title, $translation, $comment) | |
Does the actual edit. | |
Public Attributes | |
$norc = false | |
$interactive = true | |
$nocolor = false | |
Protected Member Functions | |
reportProgress ($text, $channel, $severity= 'status') | |
Protected Attributes | |
$progressCallback | |
$group |
Simple external changes syncer and conflict resolution.
Definition at line 202 of file sync-group.php.
ChangeSyncer::__construct | ( | MessageGroup $ | group | ) |
MessageGroup | $group Message group to synchronise. can be relayed back. |
Definition at line 222 of file sync-group.php.
ChangeSyncer::checkConflicts | ( | $ | code, | |
$ | startTs = false , |
|||
$ | endTs = false , |
|||
$ | changeTs = false | |||
) |
Do some conflict resolution for translations.
string | $code Language code. | |
bool|int | $startTs Time of the last export (changes in wiki after this will conflict) | |
bool|int | $endTs Time of the last export (changes in source before this won't conflict) | |
bool|int | $changeTs When change happened in the source. |
Definition at line 308 of file sync-group.php.
ChangeSyncer::color | ( | $ | color, | |
$ | text | |||
) |
Colors text for shell output.
string | $color Either blue, green or bold. | |
string | $text |
Definition at line 436 of file sync-group.php.
Referenced by checkConflicts().
ChangeSyncer::getLastGoodChange | ( | $ | title, | |
$ | startTs = false | |||
) |
Try to identify when the translation was last changed in the wiki.
Title | $title Title of the page which contains translation. | |
int|bool | $startTs Timestamp how far back to go before giving up. |
Definition at line 455 of file sync-group.php.
Referenced by checkConflicts().
ChangeSyncer::getTimestampsFromFs | ( | $ | file | ) |
Fetch last changed timestamp for any file for conflict resolution.
string | $file Filename with full path. |
Definition at line 289 of file sync-group.php.
ChangeSyncer::getTimestampsFromGit | ( | $ | file | ) |
Fetch last changed timestamp for a versioned file for conflict resolution.
string | $file Filename with full path. |
Definition at line 272 of file sync-group.php.
ChangeSyncer::getTimestampsFromSvn | ( | $ | file | ) |
Fetch last changed timestamp for a versioned file for conflict resolution.
string | $file Filename with full path. |
Definition at line 244 of file sync-group.php.
ChangeSyncer::import | ( | $ | title, | |
$ | translation, | |||
$ | comment | |||
) |
Does the actual edit.
Title | $title | |
string | $translation | |
string | $comment Edit summary. |
Definition at line 484 of file sync-group.php.
ChangeSyncer::reportProgress | ( | $ | text, | |
$ | channel, | |||
$ | severity = 'status' | |||
) | [protected] |
Definition at line 231 of file sync-group.php.
Referenced by checkConflicts(), and import().
ChangeSyncer::setProgressCallback | ( | $ | callback | ) |
Definition at line 226 of file sync-group.php.
ChangeSyncer::$group [protected] |
Definition at line 216 of file sync-group.php.
ChangeSyncer::$interactive = true |
Definition at line 210 of file sync-group.php.
ChangeSyncer::$nocolor = false |
Definition at line 213 of file sync-group.php.
ChangeSyncer::$norc = false |
Definition at line 207 of file sync-group.php.
ChangeSyncer::$progressCallback [protected] |
Definition at line 204 of file sync-group.php.