// Checkout checkouts to a given commitish.
Checkout checkouts to a given commitish.
// Checkout checkouts to a given commitish .
func (r *repo) Checkout(ctx context.Context, commitish string) error {
	out, err := r.runGitCommand(ctx, "checkout", commitish)
	if err != nil {
		return formatCommandError(err, out)
	}
	return nil
}
func ( r * repo ) Checkout ( ctx context . Context , commitish string ) error { out , err := r . runGitCommand ( ctx , " " , commitish ) if err != nil { return formatCommandError ( err , out ) } return nil }
Checkout checkouts to a given commitish.
Checkout checkouts to a given commitish .