Skip to content

Commit

Permalink
Add -F to commit search to treat keywords as strings
Browse files Browse the repository at this point in the history
  • Loading branch information
me-heer committed Jan 9, 2024
1 parent 4d1277c commit fb1c174
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions modules/git/repo_commit.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,9 @@ func (repo *Repository) searchCommits(id ObjectID, opts SearchCommitsOptions) ([
cmd.AddArguments("--all")
}

// interpret search string keywords as string instead of regex
cmd.AddArguments("-F")

// add remaining keywords from search string
// note this is done only for command created above
for _, v := range opts.Keywords {
Expand Down

0 comments on commit fb1c174

Please sign in to comment.