Re: [PATCH] git: add -N as a short option for --no-pager

2018-04-24 Thread Beat Bolli <bbo...@ewanet.ch>
On Wed, Apr 25, 2018 at 09:05:56AM +0900, Junio C Hamano wrote:
> Johannes Sixt  writes:
> 
> > In modern setups, less, the pager, uses alternate screen to show
> > the content. When it is closed, it switches back to the original
> > screen, and all content is gone.
> >
> > It is not uncommon to request that the output remains visible in
> > the terminal. For this, the option --no-pager can be used. But
> > it is a bit cumbersome to type, even when command completion is
> > available. Provide a short option, -N, to make the option easier
> > accessible.
> >
> > Signed-off-by: Johannes Sixt 
> > ---
> 
> Heh, I used to append "|cat", which is four keystrokes that is a bit
> shorter than " --no-pager", but that is only acceptable when you do
> not care about colored output ;-)
> 
> I am not absolutely certain about the choice of a single letter. I
> already checked we do not use "git -N cmd" for anything else right
> now, so I am certain about the availability, but I am not sure if
> capital 'N' is the best choice, when the other side is lowercase 'p'
> (and more importantly, the other side 'p' has mneomonic value for
> 'pagination', but 'N' merely stands for 'no' and could be negating
> anything, not related to pagination). But I agree that a short-hand
> would be welcome.
> 

I'm quite fond of the notation "-p-", but that would set a precedent for
all other "--no-" options.

Maybe the option parser could be enhanced to allow for both?

Thanks,
Beat

> > diff --git a/Documentation/git.txt b/Documentation/git.txt
> > index 4767860e72..17b50b0dc6 100644
> > --- a/Documentation/git.txt
> > +++ b/Documentation/git.txt
> > @@ -11,7 +11,7 @@ SYNOPSIS
> >  [verse]
> >  'git' [--version] [--help] [-C ] [-c =]
> >  [--exec-path[=]] [--html-path] [--man-path] [--info-path]
> > -[-p|--paginate|--no-pager] [--no-replace-objects] [--bare]
> > +[-p|--paginate|-N|--no-pager] [--no-replace-objects] [--bare]
> >  [--git-dir=] [--work-tree=] [--namespace=]
> >  [--super-prefix=]
> >   []
> > @@ -103,6 +103,7 @@ foo.bar= ...`) sets `foo.bar` to the empty string which 
> > `git config
> > configuration options (see the "Configuration Mechanism" section
> > below).
> >  
> > +-N::
> >  --no-pager::
> > Do not pipe Git output into a pager.


signature.asc
Description: PGP signature


Re: SEC_E_BUFFER_TOO_SMALL on Windows

2018-04-23 Thread Beat Bolli <bbo...@ewanet.ch>
On Mon, Apr 23, 2018 at 11:13:41AM -0500, Jason B. Nance wrote:
> Hello all,
> 
> We are seeing intermittent errors with Git 2.16.2.windows.1 on Windows
> 7 connecting to TFS 2017 (running in a Jenkins slave process):
> 
> ERROR: Error cloning remote repo 'origin'
> hudson.plugins.git.GitException: Command "C:\tools\Git\bin\git.exe
> fetch --tags --progress
> https://internal-tfs-server/tfs/project/_git/repo
> +refs/heads/*:refs/remotes/origin/*" returned status code 128:
> stdout: stderr: fatal: unable to access
> 'https://internal-tfs-server/tfs/project/_git/repo/': schannel:
> next InitializeSecurityContext failed: SEC_E_BUFFER_TOO_SMALL
> (0x80090321) - The buffers supplied to a function was too small.
> 
> I found the following thread from 2015 on a cURL list that seems to be
> similar:
> 
> https://curl.haxx.se/mail/lib-2015-04/0136.html
> 
> However, it looks like a patch was released for that issue:
> 
> https://curl.haxx.se/mail/lib-2015-04/0152.html
> 
> Rebooting the Windows client appears to resolve the issue for a time.
> 
> Has anyone else experienced this and found a resolution or workaround?

This answer seems relevant: https://stackoverflow.com/a/39217099/232775 .
The link in the answer is no longer available; the current link is
https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/4906705/ .

The obvious workaround would be to retry the request, because the error
happens randomly depending on the value of a Diffie-Hellman ephemeral
key parameter.

Cheers,
Beat


signature.asc
Description: PGP signature