Documentation
¶
Index ¶
- Variables
- func ExecuteCommand(command string, args []string, dir string) error
- func FindCommitByMessage(repo *git.Repository, origMsg string) (string, error)
- func GenerateNewCommitMessage(commit models.CommitOutput, model string, temperature float64) (models.NewCommitMessage, error)
- func GetCommandOutput(command string, args []string, dir string) (string, error)
- func GetCommitsToRewrite(repo *git.Repository, maxMsgLength, maxDiffLength int) ([]models.CommitOutput, error)
- func GetRepoName(repoPath string) string
- func RewordCommit(repoPath, targetCommit, newMessage string) error
- func SendOllamaMessage(model string, messages []ollama.Message, format json.RawMessage, ...) (string, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var MockUpdateStatusForTests bool
MockUpdateStatusForTests is a flag that can be set to disable UI updates during testing
Functions ¶
func ExecuteCommand ¶
ExecuteCommand runs a command and returns an error if it fails
func FindCommitByMessage ¶
FindCommitByMessage searches for a commit with a specific message
func GenerateNewCommitMessage ¶
func GenerateNewCommitMessage(commit models.CommitOutput, model string, temperature float64) (models.NewCommitMessage, error)
GenerateNewCommitMessage generates a new commit message using Ollama
func GetCommandOutput ¶
GetCommandOutput runs a command and returns its output
func GetCommitsToRewrite ¶
func GetCommitsToRewrite(repo *git.Repository, maxMsgLength, maxDiffLength int) ([]models.CommitOutput, error)
GetCommitsToRewrite gets a list of commits that need to be rewritten
func GetRepoName ¶
GetRepoName extracts the name of a repository from its path
func RewordCommit ¶
RewordCommit changes the message of a specific git commit
func SendOllamaMessage ¶
func SendOllamaMessage(model string, messages []ollama.Message, format json.RawMessage, temperature float64) (string, error)
SendOllamaMessage sends a request to the Ollama API
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.