Ejemplo n.º 1
0
 /// More info:
 /// https://developer.atlassian.com/bitbucket/api/2/reference/resource/repositories/%7Busername%7D/%7Brepo_slug%7D/commits#get
 /// <summary>
 /// Gets the commit information associated with a repository.
 /// By default, this call returns all the commits across all branches, bookmarks, and tags. The newest commit is first.
 /// </summary>
 /// <param name="branchOrTag">The branch or tag to get, for example, master or default.</param>
 /// <param name="commitsParameters">Optional parameters that allow to filter the commits to return.</param>
 /// <returns></returns>
 public List <Commit> ListCommits(string branchOrTag, CommitsParameters commitsParameters)
 {
     return(_repositoriesEndPoint.ListCommits(_accountName, _slug, branchOrTag, commitsParameters));
 }
Ejemplo n.º 2
0
        internal List <Commit> ListCommits(string accountName, string slug, string branchOrTag, CommitsParameters commitsParameters)
        {
            var overrideUrl = GetRepositoryUrl(accountName, slug, "commits/");

            if (!string.IsNullOrEmpty(branchOrTag))
            {
                overrideUrl += branchOrTag;
            }

            return(GetPaginatedValues <Commit>(overrideUrl, commitsParameters?.Max ?? 0, commitsParameters?.ToDictionary()));
        }
Ejemplo n.º 3
0
 /// More info:
 /// https://developer.atlassian.com/bitbucket/api/2/reference/resource/repositories/%7Busername%7D/%7Brepo_slug%7D/commits#get
 /// <summary>
 /// Gets the commit information associated with a repository.
 /// By default, this call returns all the commits across all branches, bookmarks, and tags. The newest commit is first.
 /// </summary>
 /// <param name="commitsParameters">Parameters that allow to filter the commits to return.</param>
 /// <returns></returns>
 public List <Commit> ListCommits(CommitsParameters commitsParameters)
 {
     return(_repositoriesEndPoint.ListCommits(_accountName, _slug, null, commitsParameters));
 }