Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
E
emulab-devel
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Brecht Vermeulen
emulab-devel
Commits
87d08e8b
Commit
87d08e8b
authored
13 years ago
by
Robert Ricci
Browse files
Options
Downloads
Patches
Plain Diff
Be consistent about using $GIT instead of git
... so that we can specify a different path to git if necessary
parent
4de19632
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tools/git/gitmail
+8
-6
8 additions, 6 deletions
tools/git/gitmail
with
8 additions
and
6 deletions
tools/git/gitmail
+
8
−
6
View file @
87d08e8b
...
...
@@ -272,11 +272,11 @@ if ($mailconfigfile) {
#
my
@reflines
;
if
(
$testmode
)
{
my
$fullref
=
`
git
rev-parse --symbolic-full-name
$testbranch
`;
my
$fullref
=
`
$GIT
rev-parse --symbolic-full-name
$testbranch
`;
if
(
!
$fullref
)
{
exit
(
1
);
}
my
$newrev
=
`
git
rev-parse
$fullref
$STDERRNULL
`;
my
$newrev
=
`
$GIT
rev-parse
$fullref
$STDERRNULL
`;
chomp
$newrev
;
#
...
...
@@ -444,7 +444,7 @@ sub change_type($$$) {
#
sub
rev_type
($)
{
my
(
$rev
)
=
@_
;
my
$rev_type
=
`
git
cat-file -t '
$rev
'
$STDERRNULL
`;
my
$rev_type
=
`
$GIT
cat-file -t '
$rev
'
$STDERRNULL
`;
chomp
$rev_type
;
return
$rev_type
;
}
...
...
@@ -689,7 +689,7 @@ sub commit_mail($\@$@) {
my
$actionstring
=
ucfirst
(
$ref_type
)
.
'
'
.
short_refname
(
$refname
)
.
"
has been
$what_happened
";
$short_rev
=
`
git
rev-parse --short
$refname
$STDERRNULL
`;
$short_rev
=
`
$GIT
rev-parse --short
$refname
$STDERRNULL
`;
chomp
$short_rev
;
$subject
.=
"
(
$short_rev
)
"
if
(
$short_rev
);
...
...
@@ -929,7 +929,7 @@ sub send_mail($$@) {
#
sub
short_refname
($)
{
my
(
$ref
)
=
@_
;
my
$refname
=
`
git
rev-parse --abbrev-ref
$ref
$STDERRNULL
`;
my
$refname
=
`
$GIT
rev-parse --abbrev-ref
$ref
$STDERRNULL
`;
chomp
$refname
;
# Fall back to full name if rev-parse fails for some reason
...
...
@@ -996,6 +996,8 @@ sub get_config($$) {
$getcommand
=
"
--get-all
";
}
# Note: We have to use 'git', not '$GIT' here, since the latter is fetched
# using this function
my
@value
=
`
git config
$getcommand
$CONFIGBASE
.
$var
`;
chomp
@value
;
...
...
@@ -1028,7 +1030,7 @@ sub get_config($$) {
sub
get_merge_base
($$)
{
my
(
$rev_a
,
$rev_b
)
=
@_
;
my
$mb
=
`
git
merge-base '
$rev_a
' '
$rev_b
'
`;
my
$mb
=
`
$GIT
merge-base '
$rev_a
' '
$rev_b
'
`;
chomp
$mb
;
return
$mb
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment