// GetCommitURL returns the CommitURL field if it's non-nil, zero value otherwise.
484031
func (t *Timeline) GetCommitURL() string {
	if t == nil || t.CommitURL == nil {
		return ""
	}
	return *t.CommitURL
}
896781
func (repo *Repository) GetCommit(commitID string) (*Commit, error) {
	var err error
	commitID, err = GetFullCommitID(repo.Path, commitID)
	if err != nil {
		return nil, err
	}
	id, err := NewIDFromString(commitID)
	if err != nil {
		return nil, err
	}

	return repo.getCommit(id)
}
1113582
func (r *Repository) GetGitRefsURL() string {
	if r == nil || r.GitRefsURL == nil {
		return ""
	}
	return *r.GitRefsURL
}
711354
func (r *RepositoryInvitation) GetURL() string {
	if r == nil || r.URL == nil {
		return ""
	}
	return *r.URL
}
392685
func GetCommitFileStatus(repoPath, commitID string) (*CommitFileStatus, error) {
	stdout, w := io.Pipe()
	done := make(chan struct{})
	fileStatus := NewCommitFileStatus()
	go func() {
		scanner := bufio.NewScanner(stdout)
		for scanner.Scan() {
			fields := strings.Fields(scanner.Text())
			if len(fields) < 2 {
				continue
			}

			switch fields[0][0] {
			case 'A':
				fileStatus.Added = append(fileStatus.Added, fields[1])
			case 'D':
				fileStatus.Removed = append(fileStatus.Removed, fields[1])
			case 'M':
				fileStatus.Modified = append(fileStatus.Modified, fields[1])
			}
		}
		done <- struct{}{}
	}()

	stderr := new(bytes.Buffer)
	err := NewCommand("show", "--name-status", "--pretty=format:''", commitID).RunInDirPipeline(repoPath, w, stderr)
	w.Close() // Close writer to exit parsing goroutine
	if err != nil {
		return nil, concatenateError(err, stderr.String())
	}

	<-done
	return fileStatus, nil
}
716509
func (c *Commit) GetHTMLURL() string {
	if c == nil || c.HTMLURL == nil {
		return ""
	}
	return *c.HTMLURL
}
261157
func (n *NotificationSubject) GetURL() string {
	if n == nil || n.URL == nil {
		return ""
	}
	return *n.URL
}
608730
func (r *RepositoryCommit) GetCommentsURL() string {
	if r == nil || r.CommentsURL == nil {
		return ""
	}
	return *r.CommentsURL
}
1232359
func (w *WeeklyStats) GetCommits() int {
	if w == nil || w.Commits == nil {
		return 0
	}
	return *w.Commits
}
1041091
func (r *Repository) GetAssigneesURL() string {
	if r == nil || r.AssigneesURL == nil {
		return ""
	}
	return *r.AssigneesURL
}
676041
func (p *PunchCard) GetCommits() int {
	if p == nil || p.Commits == nil {
		return 0
	}
	return *p.Commits
}
734259
func (c *CommitFile) GetBlobURL() string {
	if c == nil || c.BlobURL == nil {
		return ""
	}
	return *c.BlobURL
}
1285983
func (r *RepositoryContent) GetURL() string {
	if r == nil || r.URL == nil {
		return ""
	}
	return *r.URL
}
611183
func (c *CommitResult) GetURL() string {
	if c == nil || c.URL == nil {
		return ""
	}
	return *c.URL
}
1267937
func (c *CommitResult) GetHTMLURL() string {
	if c == nil || c.HTMLURL == nil {
		return ""
	}
	return *c.HTMLURL
}
992299
func (c *Contributor) GetURL() string {
	if c == nil || c.URL == nil {
		return ""
	}
	return *c.URL
}
543637
func (g *GistCommit) GetURL() string {
	if g == nil || g.URL == nil {
		return ""
	}
	return *g.URL
}