utils: inject Ruby path when running Gems
utils: inject Ruby path when running Gems

Particularly the `bundler` Gem requires the right Ruby binary to be in
the PATH to work correctly if the Ruby binary used to run Homebrew is
overridden via `HOMEBREW_RUBY_PATH` and thus intentionally not prefixed
to the PATH (as that would affect formulae with a Ruby dependency).

The workaround here is to prefix this path only when a Gem is activated
via `Homebrew.install_gem_setup_path!` (currently used in `brew man`,
`brew style`, and `brew tests`).

skatsuta/homebrew,saketkc/linuxbrew,scorphus/homebrew,iostat/homebrew2,hanxue/homebrew,Angeldude/linuxbrew,quantumsteve/homebrew,elyscape/homebrew,slyphon/homebrew,Asuranceturix/homebrew,georgschoelly/homebrew,knpwrs/homebrew,drbenmorgan/linuxbrew,utzig/homebrew,hongkongkiwi/homebrew,TaylorMonacelli/homebrew,sakra/homebrew,redpen-cc/homebrew,frodeaa/homebrew,dickeyxxx/homebrew,ralic/homebrew,mobileoverlord/homebrew-1,ear/homebrew,knpwrs/homebrew,emcrisostomo/homebrew,sjackman/linuxbrew,osimola/homebrew,menivaitsi/homebrew,yumitsu/homebrew,elgertam/homebrew,theeternalsw0rd/homebrew,reelsense/linuxbrew,3van/homebrew,gnubila-france/linuxbrew,ryanfb/homebrew,Chilledheart/homebrew,adamliter/homebrew,cosmo0920/homebrew,knpwrs/homebrew,scpeters/homebrew,Homebrew/linuxbrew,ExtremeMan/homebrew,polishgeeks/homebrew,vigo/homebrew,drewwells/homebrew,brunchboy/homebrew,ralic/homebrew,ablyler/homebrew,dutchcoders/homebrew,filcab/homebrew,dongcarl/homebrew,utzig/homebrew,reelsense/linuxbrew,SteveClement/homebrew,mobileoverlord/homebrew-1,MartinDelille/homebrew,reelsense/homebrew,pcottle/homebrew,jamer/homebrew,Red54/homebrew,haihappen/homebrew,afh/homebrew,gnubila-france/linuxbrew,Asuranceturix/homebrew,sjackman/linuxbrew,reelsense/homebrew,gawbul/homebrew,marcwebbie/homebrew,retrography/homebrew,scorphus/homebrew,ExtremeMan/homebrew,ear/homebrew,hanxue/homebrew,influxdb/homebrew,utzig/homebrew,getgauge/homebrew,drbenmorgan/linuxbrew,benjaminfrank/homebrew,arnested/homebrew,gawbul/homebrew,vigo/homebrew,jarrettmeyer/homebrew,esamson/homebrew,3van/homebrew,chadcatlett/homebrew,bigbes/homebrew,ilovezfs/homebrew,cosmo0920/homebrew,dgageot/homebrew,SuperNEMO-DBD/cadfaelbrew,Linuxbrew/linuxbrew,optikfluffel/homebrew,yazuuchi/homebrew,teslamint/homebrew,BrewTestBot/homebrew,Asuranceturix/homebrew,Linuxbrew/linuxbrew,filcab/homebrew,theeternalsw0rd/homebrew,scorphus/homebrew,Homebrew/homebrew,arnested/homebrew,ebouaziz/linuxbrew,nandub/homebrew,johanhammar/homebrew,quantumsteve/homebrew,kevinastone/homebrew,gicmo/homebrew,ablyler/homebrew,eighthave/homebrew,totalvoidness/homebrew,galaxy001/homebrew,kevinastone/homebrew,drbenmorgan/linuxbrew,muellermartin/homebrew,treyharris/homebrew,sometimesfood/homebrew,ebouaziz/linuxbrew,jconley/homebrew,AlexejK/homebrew,theeternalsw0rd/homebrew,3van/homebrew,danieroux/homebrew,Linuxbrew/linuxbrew,recruit-tech/homebrew,ilovezfs/homebrew,optikfluffel/homebrew,cosmo0920/homebrew,dgageot/homebrew,3van/homebrew,michaKFromParis/homebrew-sparks,gnubila-france/linuxbrew,mobileoverlord/homebrew-1,dalanmiller/homebrew,pdxdan/homebrew,drewwells/homebrew,mkrapp/homebrew,menivaitsi/homebrew,joshfriend/homebrew,emcrisostomo/homebrew,kenips/homebrew,adamliter/homebrew,decors/homebrew,hakamadare/homebrew,zchee/homebrew,keith/homebrew,DoomHammer/linuxbrew,yazuuchi/homebrew,thinker0/homebrew,chadcatlett/homebrew,dunn/homebrew,slyphon/homebrew,deorth/homebrew,miketheman/homebrew,miketheman/homebrew,iandennismiller/homebrew,bukzor/linuxbrew,Red54/homebrew,jamer/homebrew,kodabb/homebrew,yazuuchi/homebrew,scorphus/homebrew,youtux/homebrew,kenips/homebrew,redpen-cc/homebrew,danieroux/homebrew,benjaminfrank/homebrew,base10/homebrew,royhodgman/homebrew,polishgeeks/homebrew,skinny-framework/homebrew,dutchcoders/homebrew,gawbul/homebrew,ablyler/homebrew,MoSal/homebrew,scpeters/homebrew,optikfluffel/homebrew,deorth/homebrew,pdxdan/homebrew,brunchboy/homebrew,influxdata/homebrew,MoSal/homebrew,galaxy001/homebrew,SteveClement/homebrew,elyscape/homebrew,tschoonj/homebrew,michaKFromParis/homebrew-sparks,osimola/homebrew,ebouaziz/linuxbrew,Red54/homebrew,skinny-framework/homebrew,reelsense/linuxbrew,LinusU/homebrew,keith/homebrew,elgertam/homebrew,mactkg/homebrew,cprecioso/homebrew,booi/homebrew,royhodgman/homebrew,princeofdarkness76/homebrew,frodeaa/homebrew,BrewTestBot/homebrew,pcottle/homebrew,ilovezfs/homebrew,Homebrew/linuxbrew,ybott/homebrew,liamstask/homebrew,totalvoidness/homebrew,ybott/homebrew,totalvoidness/homebrew,galaxy001/homebrew,ralic/homebrew,pcottle/homebrew,mmizutani/homebrew,jarrettmeyer/homebrew,recruit-tech/homebrew,ento/homebrew,jsjohnst/homebrew,reelsense/linuxbrew,benjaminfrank/homebrew,ExtremeMan/homebrew,vigo/homebrew,kodabb/homebrew,mobileoverlord/homebrew-1,dalanmiller/homebrew,youtux/homebrew,menivaitsi/homebrew,dongcarl/homebrew,cscetbon/homebrew,feelpp/homebrew,Angeldude/linuxbrew,mactkg/homebrew,nandub/homebrew,influxdata/homebrew,Homebrew/homebrew,zchee/homebrew,ybott/homebrew,pcottle/homebrew,hanxue/homebrew,kodabb/homebrew,ear/homebrew,dplarson/homebrew,mkrapp/homebrew,emcrisostomo/homebrew,thinker0/homebrew,tutumcloud/homebrew,marcwebbie/homebrew,mactkg/homebrew,influxdata/homebrew,iandennismiller/homebrew,cprecioso/homebrew,filcab/homebrew,redpen-cc/homebrew,dplarson/homebrew,sakra/homebrew,johanhammar/homebrew,feelpp/homebrew,LinusU/homebrew,kenips/homebrew,jamer/homebrew,dickeyxxx/homebrew,feelpp/homebrew,Homebrew/linuxbrew,Chilledheart/homebrew,OJFord/homebrew,frodeaa/homebrew,quantumsteve/homebrew,haihappen/homebrew,danieroux/homebrew,feelpp/homebrew,ryanfb/homebrew,bukzor/linuxbrew,knpwrs/homebrew,esamson/homebrew,lrascao/homebrew,mmizutani/homebrew,tutumcloud/homebrew,eighthave/homebrew,sometimesfood/homebrew,jconley/homebrew,decors/homebrew,dericed/homebrew,reelsense/homebrew,ento/homebrew,Chilledheart/homebrew,yumitsu/homebrew,treyharris/homebrew,SuperNEMO-DBD/cadfaelbrew,DoomHammer/linuxbrew,SuperNEMO-DBD/cadfaelbrew,frodeaa/homebrew,influxdb/homebrew,gicmo/homebrew,hakamadare/homebrew,sjackman/linuxbrew,princeofdarkness76/homebrew,dericed/homebrew,getgauge/homebrew,retrography/homebrew,treyharris/homebrew,elgertam/homebrew,kevinastone/homebrew,michaKFromParis/homebrew-sparks,saketkc/linuxbrew,TaylorMonacelli/homebrew,iandennismiller/homebrew,alebcay/homebrew,georgschoelly/homebrew,redpen-cc/homebrew,AlexejK/homebrew,utzig/homebrew,Red54/homebrew,SteveClement/homebrew,recruit-tech/homebrew,afh/homebrew,jarrettmeyer/homebrew,apjanke/homebrew,MartinDelille/homebrew,apjanke/homebrew,skinny-framework/homebrew,esamson/homebrew,drewwells/homebrew,LinusU/homebrew,gicmo/homebrew,dickeyxxx/homebrew,kodabb/homebrew,ear/homebrew,jconley/homebrew,dericed/homebrew,deorth/homebrew,miketheman/homebrew,mmizutani/homebrew,elyscape/homebrew,royhodgman/homebrew,getgauge/homebrew,ryanfb/homebrew,Chilledheart/homebrew,vigo/homebrew,slyphon/homebrew,johanhammar/homebrew,gicmo/homebrew,marcwebbie/homebrew,nandub/homebrew,iostat/homebrew2,galaxy001/homebrew,bukzor/linuxbrew,johanhammar/homebrew,arnested/homebrew,eighthave/homebrew,SteveClement/homebrew,teslamint/homebrew,hakamadare/homebrew,optikfluffel/homebrew,haihappen/homebrew,josa42/homebrew,scpeters/homebrew,dickeyxxx/homebrew,kevinastone/homebrew,Homebrew/homebrew,dplarson/homebrew,bigbes/homebrew,georgschoelly/homebrew,elgertam/homebrew,jamer/homebrew,cscetbon/homebrew,hanxue/homebrew,base10/homebrew,BrewTestBot/homebrew,base10/homebrew,yazuuchi/homebrew,liamstask/homebrew,Angeldude/linuxbrew,skatsuta/homebrew,SuperNEMO-DBD/cadfaelbrew,brunchboy/homebrew,osimola/homebrew,quantumsteve/homebrew,tutumcloud/homebrew,TaylorMonacelli/homebrew,sferik/homebrew,TaylorMonacelli/homebrew,thinker0/homebrew,drewwells/homebrew,ryanfb/homebrew,influxdb/homebrew,sakra/homebrew,royhodgman/homebrew,ybott/homebrew,alebcay/homebrew,mmizutani/homebrew,teslamint/homebrew,influxdata/homebrew,jarrettmeyer/homebrew,nandub/homebrew,zchee/homebrew,OJFord/homebrew,polishgeeks/homebrew,menivaitsi/homebrew,tschoonj/homebrew,youtux/homebrew,lrascao/homebrew,elyscape/homebrew,teslamint/homebrew,afh/homebrew,skatsuta/homebrew,iostat/homebrew2,pdxdan/homebrew,treyharris/homebrew,jconley/homebrew,eighthave/homebrew,Asuranceturix/homebrew,hakamadare/homebrew,muellermartin/homebrew,ebouaziz/linuxbrew,booi/homebrew,liamstask/homebrew,osimola/homebrew,gnubila-france/linuxbrew,dplarson/homebrew,booi/homebrew,dutchcoders/homebrew,dongcarl/homebrew,adamliter/homebrew,haihappen/homebrew,decors/homebrew,apjanke/homebrew,ento/homebrew,dunn/homebrew,reelsense/homebrew,josa42/homebrew,hongkongkiwi/homebrew,dalanmiller/homebrew,jsjohnst/homebrew,alebcay/homebrew,Homebrew/linuxbrew,youtux/homebrew,dutchcoders/homebrew,sometimesfood/homebrew,tutumcloud/homebrew,josa42/homebrew,OJFord/homebrew,danieroux/homebrew,DoomHammer/linuxbrew,ento/homebrew,marcwebbie/homebrew,ablyler/homebrew,jsjohnst/homebrew,dunn/homebrew,apjanke/homebrew,theeternalsw0rd/homebrew,adamliter/homebrew,ralic/homebrew,MoSal/homebrew,OJFord/homebrew,chadcatlett/homebrew,Homebrew/homebrew,bigbes/homebrew,totalvoidness/homebrew,emcrisostomo/homebrew,zchee/homebrew,dericed/homebrew,keith/homebrew,dunn/homebrew,retrography/homebrew,cprecioso/homebrew,saketkc/linuxbrew,pdxdan/homebrew,sakra/homebrew,bigbes/homebrew,decors/homebrew,muellermartin/homebrew,bukzor/linuxbrew,sferik/homebrew,ExtremeMan/homebrew,LinusU/homebrew,retrography/homebrew,georgschoelly/homebrew,drbenmorgan/linuxbrew,slyphon/homebrew,joshfriend/homebrew,miketheman/homebrew,hongkongkiwi/homebrew,dgageot/homebrew,Asuranceturix/homebrew,dongcarl/homebrew,MartinDelille/homebrew,dalanmiller/homebrew,arnested/homebrew,benjaminfrank/homebrew,MoSal/homebrew,skinny-framework/homebrew,jsjohnst/homebrew,yumitsu/homebrew,princeofdarkness76/homebrew,sjackman/linuxbrew,base10/homebrew,iostat/homebrew2,saketkc/linuxbrew,recruit-tech/homebrew,esamson/homebrew,getgauge/homebrew,polishgeeks/homebrew,filcab/homebrew,AlexejK/homebrew,mkrapp/homebrew,lrascao/homebrew,liamstask/homebrew,Angeldude/linuxbrew,SteveClement/homebrew,sometimesfood/homebrew,DoomHammer/linuxbrew,iandennismiller/homebrew,Linuxbrew/linuxbrew,ilovezfs/homebrew,scpeters/homebrew,sferik/homebrew,keith/homebrew,AlexejK/homebrew,thinker0/homebrew,princeofdarkness76/homebrew,influxdb/homebrew,mactkg/homebrew,tschoonj/homebrew,cprecioso/homebrew,pcottle/homebrew,dgageot/homebrew,sferik/homebrew,cscetbon/homebrew,joshfriend/homebrew,kenips/homebrew,alebcay/homebrew,MartinDelille/homebrew,muellermartin/homebrew,brunchboy/homebrew,tschoonj/homebrew,cosmo0920/homebrew,BrewTestBot/homebrew,afh/homebrew,skatsuta/homebrew,hongkongkiwi/homebrew