func (builder CLIBuilder) Command(stdout io.Writer, stderr io.Writer) command.Command {
	command := builder.commandFactory.Create("carthage", builder.args, &command.Opts{
		Stdout: stdout,
		Stderr: stderr,
		Env:    builder.envs,
	})
	return command
}
Command returns the built command.
package carthage
import (
	"fmt"
	"github.com/bitrise-io/go-utils/env"
	"io"
	"github.com/bitrise-io/go-steputils/stepconf"
	"github.com/bitrise-io/go-utils/command"
	"github.com/bitrise-steplib/steps-carthage/cachedcarthage"
)
type CLIBuilder struct {
	args []string
	envs []string
	commandFactory command.Factory
}
func NewCLIBuilder() CLIBuilder {
	return CLIBuilder{
		args: []string{},
		envs: []string{},
		commandFactory: command.NewFactory(env.NewRepository()),
	}
}
func (builder CLIBuilder) AddGitHubToken(githubToken stepconf.Secret) cachedcarthage.CommandBuilder {
	if githubToken != "" {
		builder.envs = append(builder.envs, fmt.Sprintf("GITHUB_ACCESS_TOKEN=%s", string(githubToken)))
	}
	return builder
}
func (builder CLIBuilder) AddXCConfigFile(path string) cachedcarthage.CommandBuilder {
	if path != "" {
		builder.envs = append(builder.envs, fmt.Sprintf("XCODE_XCCONFIG_FILE=%s", path))
	}
	return builder
}
func (builder CLIBuilder) Append(args ...string) cachedcarthage.CommandBuilder {
	builder.args = append(builder.args, args...)
	return builder
}