Skip to content

Commit

Permalink
Small fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
olafurpg authored and PriNova committed Sep 11, 2024
1 parent b2217d9 commit f4aafb9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion codypy/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ async def _format_binary_name(cody_name: str, version: str) -> str:
arch = await _get_platform_arch()
formatted_arch = await _format_arch(arch)
return (
f"{cody_name}-{formatted_arch}-{version}{'.ps1' if arch == 'win-x64' else ''}"
f"{cody_name}-{formatted_arch}-{version}{'.ps1' if os.name == 'nt' else ''}"
)


Expand Down Expand Up @@ -172,6 +172,7 @@ async def _download_binary_to_path(
os.chmod(cody_binary_path, 0o755)

print(f"Created executable script at {cody_binary_path}")
return True
except Exception as err:
print(f"Error occurred while creating the script: {err}")
return False
Expand Down

0 comments on commit f4aafb9

Please sign in to comment.