* Feature suggestion: support arguments for GIT_PROXY_COMMAND & core.gitproxy
@ 2009-12-18 23:39 Joey Korkames
2009-12-19 0:58 ` Joey Korkames
2009-12-30 3:13 ` Nanako Shiraishi
0 siblings, 2 replies; 5+ messages in thread
From: Joey Korkames @ 2009-12-18 23:39 UTC (permalink / raw)
To: git
Could /connect.c be patched to support multiple arguments in
ENV[GIT_PROXY_COMMAND] and git config core.gitproxy?
For instance, something like :
GIT_PROXY_COMMAND="myproxyscript arg1 arg2"
or (way more useful):
git config core.gitproxy \
'"myproxyscript -mode git -proxy joey@gw.myhouse.com -proxy joey@bastion.foocorp.com" for foocorp.com$'
Its slightly annoying to maintain and distribute custom copies of myproxyscript
that carry the repo-specific proxy arguments inline just because git won't
pass those arguments itself (arguments that a repo's .git/config can easily
store).
I think supporting tokens (ala ssh's ProxyCommand - %h=repohost,
%p=repoport, %u=repouser) would be awesome, but that change would not be
backward-compatible with existing .git/config files or GIT_PROXY_COMMAND
utilizing-scripts. Its enough to assume that "$host $port" will always be
appended to the gitproxy arg list.
Thanks for reading, (and thnaks for git!)
-joey
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Feature suggestion: support arguments for GIT_PROXY_COMMAND & core.gitproxy
2009-12-18 23:39 Feature suggestion: support arguments for GIT_PROXY_COMMAND & core.gitproxy Joey Korkames
@ 2009-12-19 0:58 ` Joey Korkames
2009-12-30 3:13 ` Nanako Shiraishi
1 sibling, 0 replies; 5+ messages in thread
From: Joey Korkames @ 2009-12-19 0:58 UTC (permalink / raw)
To: git
I forgot to mention that this all applies to ENV[GIT_SSH] as well, which
has no correspondgin git-config option, currently.
I see there's some hardcoding of Tortoise and PuTTY's plink
argument-handling in connect.c . I think a tokenable core.sshproxy option in
~/.gitconfig would be way less hinky, IMHO.
I just played with the man options in git config and I really liked how that
worked; maybe that's a good part of the codebase to copy-paste from? I'm no
C hacker, otherwise I'd be shutting up and sending a patch...
-joey
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Feature suggestion: support arguments for GIT_PROXY_COMMAND & core.gitproxy
2009-12-18 23:39 Feature suggestion: support arguments for GIT_PROXY_COMMAND & core.gitproxy Joey Korkames
2009-12-19 0:58 ` Joey Korkames
@ 2009-12-30 3:13 ` Nanako Shiraishi
2009-12-30 8:06 ` Junio C Hamano
1 sibling, 1 reply; 5+ messages in thread
From: Nanako Shiraishi @ 2009-12-30 3:13 UTC (permalink / raw)
To: Junio C Hamano; +Cc: Joey Korkames, git
Junio, could you tell us what happened to this thread?
I think this is probably related to the "textconv" change.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Feature suggestion: support arguments for GIT_PROXY_COMMAND & core.gitproxy
2009-12-30 3:13 ` Nanako Shiraishi
@ 2009-12-30 8:06 ` Junio C Hamano
2009-12-30 11:05 ` Jeff King
0 siblings, 1 reply; 5+ messages in thread
From: Junio C Hamano @ 2009-12-30 8:06 UTC (permalink / raw)
To: Nanako Shiraishi; +Cc: Jeff King, Joey Korkames, git
Nanako Shiraishi <nanako3@lavabit.com> writes:
> Junio, could you tell us what happened to this thread?
>
> I think this is probably related to the "textconv" change.
Yeah, you guessed right. I think the unified way to launch user specified
programs would come first and then spawning proxy the same way as others
would become trivial.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Feature suggestion: support arguments for GIT_PROXY_COMMAND & core.gitproxy
2009-12-30 8:06 ` Junio C Hamano
@ 2009-12-30 11:05 ` Jeff King
0 siblings, 0 replies; 5+ messages in thread
From: Jeff King @ 2009-12-30 11:05 UTC (permalink / raw)
To: Junio C Hamano; +Cc: Nanako Shiraishi, Joey Korkames, git
On Wed, Dec 30, 2009 at 12:06:43AM -0800, Junio C Hamano wrote:
> Nanako Shiraishi <nanako3@lavabit.com> writes:
>
> > Junio, could you tell us what happened to this thread?
> >
> > I think this is probably related to the "textconv" change.
>
> Yeah, you guessed right. I think the unified way to launch user specified
> programs would come first and then spawning proxy the same way as others
> would become trivial.
As a "7/6" on top of my other series, this should just be:
diff --git a/connect.c b/connect.c
index db965c9..838146c 100644
--- a/connect.c
+++ b/connect.c
@@ -432,6 +432,7 @@ static void git_proxy_connect(int fd[2], char *host)
argv[2] = port;
argv[3] = NULL;
memset(&proxy, 0, sizeof(proxy));
+ proxy.use_shell = 1;
proxy.argv = argv;
proxy.in = -1;
proxy.out = -1;
But I will leave it to somebody who actually uses the proxy feature to
test and submit a patch.
-Peff
^ permalink raw reply related [flat|nested] 5+ messages in thread
end of thread, other threads:[~2009-12-30 11:06 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-18 23:39 Feature suggestion: support arguments for GIT_PROXY_COMMAND & core.gitproxy Joey Korkames
2009-12-19 0:58 ` Joey Korkames
2009-12-30 3:13 ` Nanako Shiraishi
2009-12-30 8:06 ` Junio C Hamano
2009-12-30 11:05 ` Jeff King
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox