Re: [PATCH] run-command.c: print env vars when GIT_TRACE is set
- From
Johannes Sixt <j6t@kdbg.org>
- Date
- Jan 11, 2018, 18:21 UTC
- Message-ID
- <efacd948-0984-ef83-c249-b4139f61a519@kdbg.org>
- In-Reply-To
- <20180111100734.GA17274@sigill.intra.peff.net>
Am 11.01.2018 um 11:07 schrieb Jeff King:
Show 10 quoted lines
> The output for a single command is pretty shell-like due to the quoting: > > $ GIT_TRACE=1 ./git upload-pack . >/dev/null > [...]run_command: 'git-upload-pack' '.' > > You could copy and paste that to a shell if you wanted. And with > environment variables, that remains so: > > $ GIT_TRACE=1 ./git ls-remote https://github.com/git/git >/dev/null > [...]run_command: 'GIT_DIR=.git' 'git-remote-https' 'https://[...]'
Not quite, though. For variable assignments to be recognized as such, the name and equal sign must not be quoted:
GIT_DIR='.git' 'git-remote-https' 'https://[...]'
-- Hannes