-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Package the AWS command-line as a "console script" entry point #5063
Comments
Hi @danizen, thanks. I looked at the installations via MSI for the AWS CLI v1 and v2, and both of these have an |
Greetings! It looks like this issue hasn’t been active in longer than a week. We encourage you to check if this is still an issue in the latest release. Because it has been longer than a week since the last update on this, and in the absence of more information, we will be closing this issue soon. If you find that this is still a problem, please feel free to provide a comment or add an upvote to prevent automatic closure, or if the issue is already closed, please feel free to open a new one. |
@kdaily, the issue and suggestion is for the Python packaging, rather than the MSI packaging. No one I know installs Python packages as MSIs, indeed most of my developers would be unable to do that, because they do not have administrative permissions. I, and my programmers, are installing it as follows:
The code at Line 51 in 8bb8c89
entry_points={'console_scripts': [
'aws = awscli.clidriver:main',
]}, Here is the documentation, but what they do not say is that for Linux/Mac, pip installs an executable script, but for Windows, it creates an exe file that loads Python though DLLs and then executes the correct Python module. |
Greetings! It looks like this issue hasn’t been active in longer than one year. We encourage you to check if this is still an issue in the latest release. In the absence of more information, we will be closing this issue soon. If you find that this is still a problem, please feel free to provide a comment or upvote with a reaction on the initial post to prevent automatic closure. If the issue is already closed, please feel free to open a new one. |
+1. This would make it easier to use the aws cli from Bazel, using py_console_script_binary |
In comparison to `scripts`, setuptools's `console_scripts` mechanism is a more portable way to register CLI executables which allows setuptools to generate the executable stub script in a manner appropriate for the platform in question. It also integrates well with bazel. In this patch we add one for the `aws` command. Fixes aws#5063
DESIRED BEHAVIOR
The aws command on Windows should be an EXE rather than a batch file, because Python supports that well, and it is low-hanging fruit.
CURRENT BEHAVIOR
aws is a batch file, and this limits how it can be integrated with some build systems.
AN EASY FIX?
This could be addressed with changes to
setup.py
, depending on how this affects Python 2.7 support. Python 2 is end of life, and on Windows, Python 2.7's install does not even include pip.MOTIVATING EXAMPLE
This should work:
Since aws is a bat file rather than an executable, this fails on Windows.
The text was updated successfully, but these errors were encountered: