modue stuff
This commit is contained in:
parent
5ad1c65310
commit
25ed7d3f8d
1 changed files with 3 additions and 3 deletions
6
main.go
6
main.go
|
|
@ -85,7 +85,7 @@ func main() {
|
||||||
case "fish":
|
case "fish":
|
||||||
fmt.Printf(`function _llm_shell_hint
|
fmt.Printf(`function _llm_shell_hint
|
||||||
set -l LLM_SUGGESTION_FILE (mktemp)
|
set -l LLM_SUGGESTION_FILE (mktemp)
|
||||||
llm-shell-hint %s --output $LLM_SUGGESTION_FILE (commandline -b)
|
llm-shell-hint %s query --output $LLM_SUGGESTION_FILE (commandline -b)
|
||||||
set -l LLM_SUGGESTION (cat $LLM_SUGGESTION_FILE)
|
set -l LLM_SUGGESTION (cat $LLM_SUGGESTION_FILE)
|
||||||
rm $LLM_SUGGESTION_FILE
|
rm $LLM_SUGGESTION_FILE
|
||||||
|
|
||||||
|
|
@ -102,7 +102,7 @@ bind ctrl-q _llm_shell_hint
|
||||||
case "bash":
|
case "bash":
|
||||||
fmt.Printf(`_llm_shell_hint() {
|
fmt.Printf(`_llm_shell_hint() {
|
||||||
local suggestion_file=$(mktemp)
|
local suggestion_file=$(mktemp)
|
||||||
llm-shell-hint %s --output "$suggestion_file" -- "$READLINE_LINE"
|
llm-shell-hint %s query --output "$suggestion_file" -- "$READLINE_LINE"
|
||||||
local suggestion=$(<"$suggestion_file")
|
local suggestion=$(<"$suggestion_file")
|
||||||
rm "$suggestion_file"
|
rm "$suggestion_file"
|
||||||
|
|
||||||
|
|
@ -118,7 +118,7 @@ bind -x '"\C-q":_llm_shell_hint'
|
||||||
case "zsh":
|
case "zsh":
|
||||||
fmt.Printf(`_llm_shell_hint() {
|
fmt.Printf(`_llm_shell_hint() {
|
||||||
local suggestion_file=$(mktemp)
|
local suggestion_file=$(mktemp)
|
||||||
llm-shell-hint %s --output "$suggestion_file" -- "$BUFFER"
|
llm-shell-hint %s query --output "$suggestion_file" -- "$BUFFER"
|
||||||
local suggestion=$(<"$suggestion_file")
|
local suggestion=$(<"$suggestion_file")
|
||||||
rm "$suggestion_file"
|
rm "$suggestion_file"
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue