Skip to content

Commit

Permalink
Enable shell mode
Browse files Browse the repository at this point in the history
  • Loading branch information
mayankpatibandla committed Apr 16, 2024
1 parent e36eec7 commit c00e253
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pros/cli/misc_commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ def setup_autocomplete(shell, config_path, force):
if shell in ('pwsh', 'powershell') and config_path is None:
try:
profile_command = f'{shell} -NoLogo -NoProfile -Command "Write-Output $PROFILE"' if os.name == 'nt' else f"{shell} -NoLogo -NoProfile -Command 'Write-Output $PROFILE'"
default_config_paths[shell] = subprocess.run(profile_command, shell=True, capture_output=True, check=True).stdout.decode().strip()
default_config_paths[shell] = subprocess.run(profile_command, shell=True, capture_output=True, check=True, text=True).stdout.strip()
except subprocess.CalledProcessError as exc:
raise click.UsageError("Failed to determine the PowerShell profile path. Please specify a valid config file.") from exc

Expand Down

0 comments on commit c00e253

Please sign in to comment.