git-p4: add P4 jobs to git commit message
When migrating from Perforce to git the information about P4 jobs associated with P4 changelists is lost. Having these jobs listed on messages of related git commits enables smooth migration for projects that take advantage of e.g. JIRA integration (which uses jobs on Perforce side and parses commit messages on git side). The jobs are added to the message in the same format as is expected when migrating in the reverse direction. Signed-off-by: Jan Durovec <jan.durovec@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
a98772c63f
commit
26e6a27d69
@@ -160,6 +160,15 @@ p4_add_user () {
|
||||
EOF
|
||||
}
|
||||
|
||||
p4_add_job () {
|
||||
p4 job -f -i <<-EOF
|
||||
Job: $1
|
||||
Status: open
|
||||
User: dummy
|
||||
Description:
|
||||
EOF
|
||||
}
|
||||
|
||||
retry_until_success () {
|
||||
timeout=$(($(time_in_seconds) + $RETRY_TIMEOUT))
|
||||
until "$@" 2>/dev/null || test $(time_in_seconds) -gt $timeout
|
||||
|
||||
Reference in New Issue
Block a user