diff options
author | flu0r1ne <flu0r1ne@flu0r1ne.net> | 2023-05-11 01:27:58 -0500 |
---|---|---|
committer | flu0r1ne <flu0r1ne@flu0r1ne.net> | 2023-05-11 01:27:58 -0500 |
commit | 280259deb57d8c18f7655e4ecd79ba137ca0a37c (patch) | |
tree | 1945bd6613b7a7bb97e8a2f07326b5b61819aeff /src/gpt_chat_cli/argparsing.py | |
parent | 8bc4d723f9e223b61a8d601e3bd1083f31b89322 (diff) | |
download | gpt-chat-cli-280259deb57d8c18f7655e4ecd79ba137ca0a37c.tar.xz gpt-chat-cli-280259deb57d8c18f7655e4ecd79ba137ca0a37c.zip |
Add slash command and editing with an arbitrary editor
Diffstat (limited to 'src/gpt_chat_cli/argparsing.py')
-rw-r--r-- | src/gpt_chat_cli/argparsing.py | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/gpt_chat_cli/argparsing.py b/src/gpt_chat_cli/argparsing.py index a96e81c..703a13b 100644 --- a/src/gpt_chat_cli/argparsing.py +++ b/src/gpt_chat_cli/argparsing.py @@ -124,14 +124,14 @@ def _construct_parser() \ "-n", "--n-completions", type=int, - default=os.getenv('f{_GPT_CLI_ENV_PREFIX}N_COMPLETIONS', 1), + default=os.getenv(f'{_GPT_CLI_ENV_PREFIX}N_COMPLETIONS', 1), help="How many chat completion choices to generate for each input message.", ) parser.add_argument( "--system-message", type=str, - default=os.getenv('f{_GPT_CLI_ENV_PREFIX}SYSTEM_MESSAGE'), + default=os.getenv(f'{_GPT_CLI_ENV_PREFIX}SYSTEM_MESSAGE'), help="Specify an alternative system message.", ) @@ -174,6 +174,13 @@ def _construct_parser() \ help="Start an interactive session" ) + parser.add_argument( + "--interactive-editor", + type=str, + default=os.getenv(f'{_GPT_CLI_ENV_PREFIX}INTERACTIVE_EDITOR'), + help="The editor which is launched by default using the /edit command in interactive mode" + ) + initial_prompt = parser.add_mutually_exclusive_group() initial_prompt.add_argument( |