Skip to content

Commit

Permalink
Save autocomplete script in PROS directory
Browse files Browse the repository at this point in the history
  • Loading branch information
mayankpatibandla committed Jun 6, 2024
1 parent 5fd6f96 commit 719da6d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pros/cli/misc_commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,8 @@ def setup_autocomplete(shell, config_path, force):
raise click.UsageError(f"Config file {config_path} does not exist. Please specify a valid config file.")

# Write the autocomplete script to a shell script file
script_file = config_path.parent / _SCRIPT_FILES[shell]
script_file = Path(click.get_app_dir("PROS")) / "autocomplete" / _SCRIPT_FILES[shell]
script_file.parent.mkdir(exist_ok=True)
with script_file.open('w') as f:
f.write(_get_shell_script(shell))

Expand Down

0 comments on commit 719da6d

Please sign in to comment.