Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15417905
D7766.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D7766.diff
View Options
Index: src/applications/diffusion/engine/DiffusionCommitHookEngine.php
===================================================================
--- src/applications/diffusion/engine/DiffusionCommitHookEngine.php
+++ src/applications/diffusion/engine/DiffusionCommitHookEngine.php
@@ -733,13 +733,26 @@
private function findSubversionRefUpdates() {
- // TODO: Implement.
+ // Subversion doesn't have any kind of mutable ref metadata.
return array();
}
private function findSubversionContentUpdates(array $ref_updates) {
- // TODO: Implement.
- return array();
+ list($youngest) = execx(
+ 'svnlook youngest %s',
+ $this->subversionRepository);
+ $ref_new = (int)$youngest + 1;
+
+ $ref_flags = 0;
+ $ref_flags |= PhabricatorRepositoryPushLog::CHANGEFLAG_ADD;
+ $ref_flags |= PhabricatorRepositoryPushLog::CHANGEFLAG_APPEND;
+
+ $ref_content = $this->newPushLog()
+ ->setRefType(PhabricatorRepositoryPushLog::REFTYPE_COMMIT)
+ ->setRefNew($ref_new)
+ ->setChangeFlags($ref_flags);
+
+ return array($ref_content);
}
Index: src/applications/repository/storage/PhabricatorRepositoryPushLog.php
===================================================================
--- src/applications/repository/storage/PhabricatorRepositoryPushLog.php
+++ src/applications/repository/storage/PhabricatorRepositoryPushLog.php
@@ -16,7 +16,6 @@
const REFTYPE_BRANCH = 'branch';
const REFTYPE_TAG = 'tag';
const REFTYPE_BOOKMARK = 'bookmark';
- const REFTYPE_SVN = 'svn';
const REFTYPE_COMMIT = 'commit';
const CHANGEFLAG_ADD = 1;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Mar 21, 7:19 PM (3 d, 22 h ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7715918
Default Alt Text
D7766.diff (1 KB)
Attached To
Mode
D7766: Add Subversion ref and content logs to pre-commit hooks
Attached
Detach File
Event Timeline
Log In to Comment