Skip to content

Commit

Permalink
Fix spelling of committish
Browse files Browse the repository at this point in the history
The official git glossary (https://git-scm.com/docs/gitglossary),
spells this commit-ish or committish. Since we can't do the former,
use the latter consistently. We had three different spellings.
  • Loading branch information
Keno committed Apr 13, 2020
1 parent 24d038a commit 8b6cadb
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion stdlib/LibGit2/src/LibGit2.jl
Original file line number Diff line number Diff line change
Expand Up @@ -728,7 +728,7 @@ function merge!(repo::GitRepo;
"There is no fetch reference for this branch."))
end
Base.map(fh->GitAnnotated(repo,fh), fheads)
else # merge commitish
else # merge committish
[GitAnnotated(repo, committish)]
end
else
Expand Down
6 changes: 3 additions & 3 deletions stdlib/LibGit2/src/merge.jl
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
GitAnnotated(repo::GitRepo, commit_id::GitHash)
GitAnnotated(repo::GitRepo, ref::GitReference)
GitAnnotated(repo::GitRepo, fh::FetchHead)
GitAnnotated(repo::GitRepo, comittish::AbstractString)
GitAnnotated(repo::GitRepo, committish::AbstractString)
An annotated git commit carries with it information about how it was looked up and
why, so that rebase or merge operations have more information about the context of
Expand Down Expand Up @@ -40,8 +40,8 @@ function GitAnnotated(repo::GitRepo, fh::FetchHead)
return GitAnnotated(repo, ann_ref_ref[])
end

function GitAnnotated(repo::GitRepo, comittish::AbstractString)
obj = GitObject(repo, comittish)
function GitAnnotated(repo::GitRepo, committish::AbstractString)
obj = GitObject(repo, committish)
cmt = peel(GitCommit, obj)
return GitAnnotated(repo, GitHash(cmt))
end
Expand Down
20 changes: 10 additions & 10 deletions stdlib/LibGit2/src/repository.jl
Original file line number Diff line number Diff line change
Expand Up @@ -263,32 +263,32 @@ end
peel(obj::GitObject) = peel(GitObject, obj)

"""
LibGit2.GitDescribeResult(commitish::GitObject; kwarg...)
LibGit2.GitDescribeResult(committish::GitObject; kwarg...)
Produce a `GitDescribeResult` of the `commitish` `GitObject`, which
Produce a `GitDescribeResult` of the `committish` `GitObject`, which
contains detailed information about it based on the keyword argument:
* `options::DescribeOptions=DescribeOptions()`
A git description of a `commitish` object looks for the tag (by default, annotated,
although a search of all tags can be performed) which can be reached from `commitish`
which is most recent. If the tag is pointing to `commitish`, then only the tag is
A git description of a `committish` object looks for the tag (by default, annotated,
although a search of all tags can be performed) which can be reached from `committish`
which is most recent. If the tag is pointing to `committish`, then only the tag is
included in the description. Otherwise, a suffix is included which contains the
number of commits between `commitish` and the most recent tag. If there is no such
number of commits between `committish` and the most recent tag. If there is no such
tag, the default behavior is for the description to fail, although this can be
changed through `options`.
Equivalent to `git describe <commitish>`. See [`DescribeOptions`](@ref) for more
Equivalent to `git describe <committish>`. See [`DescribeOptions`](@ref) for more
information.
"""
function GitDescribeResult(commitish::GitObject;
function GitDescribeResult(committish::GitObject;
options::DescribeOptions=DescribeOptions())
ensure_initialized()
result_ptr_ptr = Ref{Ptr{Cvoid}}(C_NULL)
@check ccall((:git_describe_commit, :libgit2), Cint,
(Ptr{Ptr{Cvoid}}, Ptr{Cvoid}, Ptr{DescribeOptions}),
result_ptr_ptr, commitish.ptr, Ref(options))
return GitDescribeResult(commitish.owner, result_ptr_ptr[])
result_ptr_ptr, committish.ptr, Ref(options))
return GitDescribeResult(committish.owner, result_ptr_ptr[])
end

"""
Expand Down

0 comments on commit 8b6cadb

Please sign in to comment.