Kiwi / clyde

Next-generation libalpm/makepkg wrapper.
https://kiwi.github.io/clyde
Other
63 stars 8 forks source link

AUR features not working behind proxy #31

Open archme opened 14 years ago

archme commented 14 years ago

At least the AUR features within clyde do not work behind a proxy. eg: "clyde -Ss clyde" returns nothing behind a proxy (squid)

I think best approach would be to honor the $http_proxy environment variable, like most other console apps (including pacman).

Kiwi commented 14 years ago

I am really not sure how to fix this as I do not really know anything about $http_proxy or how to handle it or even what it is, do you know anything more about it that would be useful to me resolving the issue?

ijanos commented 14 years ago

It should work fine with a proxifier program like tsocks or proxychains. I think adding proxy support should be low priority.

mickael9 commented 14 years ago

Why not use luacurl or lua-cURL ? Curl supports SOCKS and HTTP proxies, and it honours http_proxy environment variable.

http://curl.haxx.se/libcurl/lua/

neenaoffline commented 14 years ago

I fixed it quite crudely. http://gist.github.com/589444

Just added two lines of code, after looking at http://w3.impa.br/~diego/software/luasocket/http.html

I'm pretty sure there is a better way to do it. (with just one line.)

mickael9 commented 14 years ago

Unfortunately, luasocket doesn't support proxy authentification.

neenaoffline commented 14 years ago

Doesn't this work? "http://user:password@host:port"?

mickael9 commented 14 years ago

The user and password part of the proxy url is ignored by luasocket

juster commented 13 years ago

I have a branch that uses lua-cURL that I can merge into master. I will just have to coordinate things so that the deps for the AUR package are changed.

Could anyone help me test out the lua-cURL branch proxy stuff? I don't have a proxy to try it out with.

juster commented 13 years ago

Oops I clicked the wrong button and closed this. Heh. Reopened it.

mickael9 commented 13 years ago

I can test it.

Where can I find it?

juster commented 13 years ago

Ok I think I got it working. Here are instructions to install the lua-curl branch.

If you don't have the git repository clone already, cd to a directory where you want th e clyde repo dir contained and type:

git clone git://github.com/Kiwi/clyde.git
cd clyde

edit: If you already have the clyde repository checked out type this in the repo dir instead:

git pull

Now from the repository's directory, type:

git checkout lua-curl
makepkg

Then install the package:

sudo pacman -U clyde-0.03.07-1.i686.pkg.tar.xz

Or whatever the package filename happens to be.

mickael9 commented 13 years ago

Seems to work fine

juster commented 13 years ago

Cool thanks.

petelewis commented 13 years ago

Hi - any chance this could be ported to the >3.5 version? Also, any plans for it to be merged?

juster commented 13 years ago

No it doesn't look promising.