Skip to content

renaming VAR for multiline option (-b | --big-prompt) option and its … #136

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions chatgpt.sh
Original file line number Diff line number Diff line change
Expand Up @@ -263,8 +263,8 @@ while [[ "$#" -gt 0 ]]; do
shift
shift
;;
--multi-line-prompt)
MULTI_LINE_PROMPT=true
-b | --big-prompt)
BIG_PROMPT=true
shift
;;
-c | --chat-context)
Expand All @@ -288,10 +288,10 @@ MAX_TOKENS=${MAX_TOKENS:-1024}
MODEL=${MODEL:-gpt-3.5-turbo}
SIZE=${SIZE:-512x512}
CONTEXT=${CONTEXT:-false}
MULTI_LINE_PROMPT=${MULTI_LINE_PROMPT:-false}
BIG_PROMPT=${BIG_PROMPT:-false}

# create our temp file for multi-line input
if [ $MULTI_LINE_PROMPT = true ]; then
if [ $BIG_PROMPT = true ]; then
USER_INPUT_TEMP_FILE=$(mktemp)
trap 'rm -f ${USER_INPUT}' EXIT
fi
Expand Down Expand Up @@ -319,7 +319,7 @@ fi
while $running; do

if [ -z "$pipe_mode_prompt" ]; then
if [ $MULTI_LINE_PROMPT = true ]; then
if [ $BIG_PROMPT = true ]; then
echo -e "\nEnter a prompt: (Press Enter then Ctrl-D to send)"
cat >"${USER_INPUT_TEMP_FILE}"
input_from_temp_file=$(cat "${USER_INPUT_TEMP_FILE}")
Expand Down