mirror of
https://github.com/facebook/sapling.git
synced 2024-10-10 16:57:49 +03:00
4f207dd263
Summary: The phabdiff template mapping returns the phabricator diff id for the commit (based on commit message). for example: $ hg log -r master --template '{phabdiff}\n' D1485506 Test Plan: - unit tests addded Reviewers: sid0, durham Reviewed By: durham Differential Revision: https://phabricator.fb.com/D1622192 Tasks: 5124920
21 lines
455 B
Perl
21 lines
455 B
Perl
$ echo "[extensions]" >> $HGRCPATH
|
|
$ echo "gitlookup = $TESTDIR/../phabdiff.py" >> $HGRCPATH
|
|
|
|
Setup repo
|
|
|
|
$ hg init repo
|
|
$ cd repo
|
|
|
|
Test phabdiff template mapping
|
|
|
|
$ echo a > a
|
|
$ hg commit -Aqm "Differential Revision: https://phabricator.fb.com/D1234"
|
|
$ hg log --template "{phabdiff}\n"
|
|
D1234
|
|
|
|
$ echo b > b
|
|
$ hg commit -Aqm "Differential Revision: https://phabricator.fb.com/D5678"
|
|
$ hg log --template "{phabdiff}\n"
|
|
D5678
|
|
D1234
|