Documentation ¶
Overview ¶
Package app is the main package for the application.
Index ¶
Constants ¶
View Source
const ( // ErrEmptyDescribeInput is the error message when the describe command is // invoked without any input. ErrEmptyDescribeInput xerrors.Error = "missing image file to describe" // ErrTooManyImages is the error message when the describe command is // invoked with more than one input. ErrTooManyImages xerrors.Error = "too many image files to describe; please provide only one" // ErrInvalidImageType is the error message when the describe command is // invoked with an invalid image file type. ErrInvalidImageType xerrors.Error = "invalid image file type; please provide a PNG, JPG, JPEG, or GIF file" // ErrInvalidProvider is the error message when the describe command is // invoked with an invalid AI provider. ErrInvalidProvider xerrors.Error = "invalid AI provider; please refer to the documentation for a list of valid providers" )
View Source
const ( // ErrEmptyDraftInput is the error message when the draft command is // invoked without any input. ErrEmptyDraftInput xerrors.Error = "missing input for draft; please provide a file with your notes" // ErrTooManyNotes is the error message when the draft command is // invoked with more than one input. ErrTooManyNotes xerrors.Error = "too many notes files; please provide only one" // ErrInvalidFiletype is the error message when the draft command is // invoked with a file that is not a text file. ErrInvalidFiletype xerrors.Error = "invalid filetype; please provide a TXT or MD file" )
View Source
const ( // ErrEmptyInput is returned when no file is provided by the user. ErrEmptyInput xerrors.Error = "missing file to review" // ErrInvalidAPIKey is returned when the user does not provide an API key // for the given provider or provides an invalid one. ErrInvalidAPIKey xerrors.Error = "missing or invalid API key" // ErrTooMuchInput is returned when the user provides more than one file. ErrTooMuchInput xerrors.Error = "too many files to review; please provide only one file" )
Variables ¶
This section is empty.
Functions ¶
func DescribeAction ¶
func DescribeAction(ctx *cli.Context) error
DescribeAction is the action to perform when the describe command is invoked.
func DraftAction ¶
func DraftAction(ctx *cli.Context) error
DraftAction is the action to perform when the draft command is invoked.
func ReviewAction ¶
func ReviewAction(ctx *cli.Context) error
ReviewAction is the main action for the application.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.