1 |
On Monday 23 March 2009 12:45:55 Nirbheek Chauhan wrote: |
2 |
> On Mon, Mar 23, 2009 at 3:33 PM, Timothy Redaelli <drizzt@g.o> wrote: |
3 |
> > Hi, |
4 |
> > Some repositories has the git (or svn) and http support. I saw that we |
5 |
> > choose the git/svn one (it's faster i know, but it does not works under |
6 |
> > proxy). |
7 |
> > |
8 |
> > I propose a E{GIT,SVN}_REPO_HTTP_URI (or similar) variable that uses the |
9 |
> > http variant when the global use is set (or we can use the http_proxy env |
10 |
> > variable). |
11 |
> > |
12 |
> > What do you think? |
13 |
> |
14 |
> Here's what I did: |
15 |
> |
16 |
> Install net-misc/connect |
17 |
> Save the script below and do `export GIT_PROXY_COMMAND=/path/to/script` |
18 |
> set http_proxy, and everything works dandy. |
19 |
> |
20 |
> Maybe this can be done inside the eclass if http_proxy is set? :) |
21 |
> |
22 |
> ---- |
23 |
> |
24 |
> proxy=${http_proxy#http://} |
25 |
> host=${proxy##*@} |
26 |
> auth=${proxy%@*} |
27 |
> if test "${auth}" != "${proxy}"; then |
28 |
> export HTTP_PROXY_USER=${auth%%:*} |
29 |
> export HTTP_PROXY_PASSWORD=${auth##*:} |
30 |
> fi |
31 |
> connect -H ${host} $1 $2 |
32 |
|
33 |
Some environments has squid with CONNECT filtered only to a few known ports :( |
34 |
|
35 |
-- |
36 |
Timothy `Drizzt` Redaelli |
37 |
FreeSBIE Developer, Gentoo Developer, GUFI Staff |
38 |
There are two major products that come out of Berkeley: LSD and UNIX. |
39 |
We don't believe this to be a coincidence. -- Jeremy S. Anderson |