Reset to remote master when updating git clones
Reset to remote master when updating git clones

When installing with --HEAD, cached repo clones do "git fetch origin"
followed by "git reset --hard". This will only reset the working tree
and index to the state of the local HEAD, but Homebrew will think it's
updated and install anyway. "git reset --hard origin/master" will
achieve the desired result.

Should fix Homebrew/homebrew#7613.

Signed-off-by: Jack Nagel <43386ce32af96f5c56f2a88e458cb94cebee3751@gmail.com>

vitorgalvao/brew,Linuxbrew/brew,sjackman/homebrew,ilovezfs/brew,pseudocody/brew,MikeMcQuaid/brew,JCount/brew,rwhogg/brew,Homebrew/brew,mistydemeo/homebrew,jmsundar/brew,mgrimes/brew,JCount/brew,sjackman/homebrew,bfontaine/brew,jmsundar/brew,ilovezfs/brew,EricFromCanada/brew,muellermartin/dist,AnastasiaSulyagina/brew,claui/brew,reelsense/brew,vitorgalvao/brew,reelsense/brew,rwhogg/brew,EricFromCanada/brew,nandub/brew,claui/brew,nandub/brew,alyssais/brew,reitermarkus/brew,rwhogg/brew,maxim-belkin/brew,reitermarkus/brew,hanxue/linuxbrew,mahori/brew,nandub/brew,claui/brew,pseudocody/brew,Linuxbrew/brew,JCount/brew,pseudocody/brew,vitorgalvao/brew,ilovezfs/brew,Homebrew/brew,MikeMcQuaid/brew,amar-laksh/brew_sudo,zmwangx/brew,jmsundar/brew,aw1621107/brew,AnastasiaSulyagina/brew,EricFromCanada/brew,sjackman/homebrew,palxex/brew,palxex/brew,konqui/brew,Homebrew/brew,DomT4/brew,mgrimes/brew,gregory-nisbet/brew,reitermarkus/brew,mistydemeo/homebrew,staticfloat/brew,amar-laksh/brew_sudo,tonyg/homebrew,bfontaine/brew,sjackman/homebrew,MikeMcQuaid/brew,mahori/brew,zmwangx/brew,Linuxbrew/brew,vitorgalvao/brew,konqui/brew,bfontaine/brew,DomT4/brew,zmwangx/brew,palxex/brew,DomT4/brew,gregory-nisbet/brew,gordonmcshane/homebrew,tonyg/homebrew,aw1621107/brew,aw1621107/brew,muellermartin/dist,staticfloat/brew,toonetown/homebrew,tonyg/homebrew,gregory-nisbet/brew,nandub/brew,mgrimes/brew,reitermarkus/brew,MikeMcQuaid/brew,DomT4/brew,Homebrew/brew,amar-laksh/brew_sudo,staticfloat/brew,maxim-belkin/brew,mistydemeo/homebrew,alyssais/brew,muellermartin/dist,gordonmcshane/homebrew,hanxue/linuxbrew,maxim-belkin/brew,hanxue/linuxbrew,claui/brew,AnastasiaSulyagina/brew,mahori/brew,konqui/brew,toonetown/homebrew,EricFromCanada/brew,alyssais/brew,konqui/brew,reelsense/brew,gordonmcshane/homebrew,mahori/brew,JCount/brew,Linuxbrew/brew,toonetown/homebrew