spulec / uncurl

A library to convert curl requests to python-requests.
Apache License 2.0
615 stars 96 forks source link

Added proxy and proxy auth flags from Curl. #53

Closed mukthy closed 2 years ago

mukthy commented 2 years ago

Now it should detect this below curl:

curl 'https://pypi.python.org/pypi/uncurl' -U user: -x proxy.python.org:8080

and convert it to a python code:

requests.get("https://pypi.python.org/pypi/uncurl", headers={}, cookies={}, auth=(), proxies={'http': 'http://user:@proxy.python.org:8080/', 'https': 'http://user:@proxy.python.org:8080/'}, )

spulec commented 2 years ago

Looks great; thanks!

mukthy commented 2 years ago

thanks for approving 👍