aider: Added a new argument --chat-history-file with a default value of .aider.chat.history.md.

# Context:
USER: add a new arg --chat-history-file arg which is similar to --input-history-file but has a default of .aider.chat.history.md
ASSISTANT: To add the new argument `--chat-history-file`, you can add a new `parser.add_argument()` call in the `aider/main.py` file. Here's the change:

```python
aider/main.py
<<<<<<< ORIGINAL
    parser.add_argument(
        "--input-history-file",
        metavar="INPUT_HISTORY_FILE",
        default=os.environ.get(f"{env_prefix}INPUT_HISTORY_FILE", ".aider.input.history"),
        help=(
            "Specify the chat input history file (default: .aider.input.history,"
            f" ${env_prefix}INPUT_HISTORY_FILE)"
        ),
    )
=======
    parser.add_argument(
        "--input-history-file",
        metavar="INPUT_HISTORY_FILE",
        default=os.environ.get(f"{env_prefix}INPUT_HISTORY_FILE", ".aider.input.history"),
        help=(
            "Specify the chat input history file (default: .aider.input.history,"
            f" ${env_prefix}INPUT_HISTORY_FILE)"
        ),
    )
    parser.add_argument(
        "--chat-history-file",
        metavar="CHAT_HISTORY_FILE",
        default=os.environ.get(f"{env_prefix}CHAT_HISTORY_FILE", ".aider.chat.history.md"),
        help=(
            "Specify the chat history file (default: .aider.chat.history.md,"
            f" ${env_prefix}CHAT_HISTORY_FILE)"
        ),
    )
>>>>>>> UPDATED
```

This will add the new `--chat-history-file` argument with a default value of `.aider.chat.history.md`.
This commit is contained in:
Paul Gauthier 2023-05-12 14:00:12 -07:00
parent 200ecf5a1f
commit e44677327f

View file

@ -27,6 +27,15 @@ def main(args=None):
f" ${env_prefix}INPUT_HISTORY_FILE)"
),
)
parser.add_argument(
"--chat-history-file",
metavar="CHAT_HISTORY_FILE",
default=os.environ.get(f"{env_prefix}CHAT_HISTORY_FILE", ".aider.chat.history.md"),
help=(
"Specify the chat history file (default: .aider.chat.history.md,"
f" ${env_prefix}CHAT_HISTORY_FILE)"
),
)
parser.add_argument(
"--model",
metavar="MODEL",