mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-29 00:35:00 +00:00
style: Reformat code to improve linter compliance
This commit is contained in:
parent
93b86a8800
commit
c79db2581b
2 changed files with 17 additions and 6 deletions
|
@ -826,7 +826,10 @@ def get_parser(default_config_files, git_root):
|
|||
"--notifications-command",
|
||||
metavar="COMMAND",
|
||||
default=None,
|
||||
help="Specify a command to run for notifications instead of the terminal bell. If not specified, a default command for your OS may be used.",
|
||||
help=(
|
||||
"Specify a command to run for notifications instead of the terminal bell. If not"
|
||||
" specified, a default command for your OS may be used."
|
||||
),
|
||||
)
|
||||
group.add_argument(
|
||||
"--detect-urls",
|
||||
|
|
18
aider/io.py
18
aider/io.py
|
@ -962,11 +962,14 @@ class InputOutput:
|
|||
def get_default_notification_command(self):
|
||||
"""Return a default notification command based on the operating system."""
|
||||
import platform
|
||||
|
||||
|
||||
system = platform.system()
|
||||
|
||||
|
||||
if system == "Darwin": # macOS
|
||||
return "osascript -e 'display notification \"Aider is waiting for your input\" with title \"Aider\"'"
|
||||
return (
|
||||
'osascript -e \'display notification "Aider is waiting for your input" with title'
|
||||
' "Aider"\''
|
||||
)
|
||||
elif system == "Linux":
|
||||
# Check for common Linux notification tools
|
||||
for cmd in ["notify-send", "zenity"]:
|
||||
|
@ -978,8 +981,13 @@ class InputOutput:
|
|||
return None # No known notification tool found
|
||||
elif system == "Windows":
|
||||
# PowerShell notification
|
||||
return "powershell -command \"[System.Reflection.Assembly]::LoadWithPartialName('System.Windows.Forms'); [System.Windows.Forms.MessageBox]::Show('Aider is waiting for your input', 'Aider')\""
|
||||
|
||||
return (
|
||||
"powershell -command"
|
||||
" \"[System.Reflection.Assembly]::LoadWithPartialName('System.Windows.Forms');"
|
||||
" [System.Windows.Forms.MessageBox]::Show('Aider is waiting for your input',"
|
||||
" 'Aider')\""
|
||||
)
|
||||
|
||||
return None # Unknown system
|
||||
|
||||
def ring_bell(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue