{"modulePath":"github.com/mackee/git-credential-github-apps","version":"v1.1.2-0.20250118114933-4fe2cf020354","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package githubapps\n\n## Variables\n\n```go\nvar (\n\tErrShowHelp = errors.New(\"receive show help args\")\n)\n```\n\n## Types\n\n```go\ntype Auther interface {\n\tFetchToken(context.Context) (string, error)\n}\n```\nAuther provides API Token with authentication on GitHub Apps.\n\n```go\nfunc NewAutherFromFile(privateKey string, appID int64, options ...AutherOption) (Auther, error)\n```\nNewAutherFromFile is constructor with filename that private key for Auther.\n\n```go\ntype AutherOption func(*auther) error\n```\nAutherOption is set parameter. This is like a Functional Option Pattern.\n\n```go\nfunc WithBaseURL(base string) AutherOption\n```\nWithBaseURL provides change api endpoint. For GitHub Enterprise\n\n```go\nfunc WithInstallationID(id int64) AutherOption\n```\nWithInstallationID is option parameter with installation ID for Auther.\n\n```go\nfunc WithLogin(ctx context.Context, login string) AutherOption\n```\nWithLogin is optional parameter for Auther. This provides to search a installation ID from login name.\n\n```go\nfunc WithStore(store Store) AutherOption\n```\nWithStore provides injection token store to Auther.\n\n```go\ntype Runner struct {\n\t// contains filtered or unexported fields\n}\n```\nRunner provides retrieving token\n\n```go\nfunc ParseArgs() (*Runner, error)\n```\nParseArgs is retrieve github apps credentials with command line options.\n\n```go\nfunc (r *Runner) Args() []string\n```\nArgs returns command options not contains parsed.\n\n```go\nfunc (r *Runner) Hostname() string\n```\nHostname returns hostname from arguments\n\n```go\nfunc (r *Runner) Run(ctx context.Context) (string, error)\n```\nRun returns credentials\n\n```go\ntype Store interface {\n\tSave(token string, expire time.Time) error\n\tToken() string\n\tExpired() bool\n}\n```\nStore is store for token and expires.\n\n```go\nfunc NewFileStore(path string) (Store, error)\n```\nNewFileStore returns Store from path of credential file\n\n","path":"github.com/mackee/git-credential-github-apps/githubapps","name":"githubapps","synopsis":"","isRedistributable":true}
