File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -30,7 +30,7 @@ function CheckAdminMode
3030function CheckPowerShellVersion
3131{
3232 if ($PSVersionTable.PSVersion.Major -lt 5 ) {
33- Write-Host " You are not running PowerShell version 5+, and cannot make a full installation (Post -git requires it)." - Foreground Red
33+ Write-Host " You are not running PowerShell version 5+, and cannot make a full installation (posh -git requires it)." - Foreground Red
3434 Write-Host " To upgrade, you can install Chocolatey through the following command, followed by a restart:" - Foreground Cyan
3535 Write-Host " Set-ExecutionPolicy Bypass -Scope Process -Force; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" - Foreground Gray
3636 Write-Host " After that, run the following code to install the new verison of PowerShell:"
@@ -217,26 +217,10 @@ function SetupPoshGit
217217{
218218 try
219219 {
220- # Download and install posh-git
221- Write-Host " Download and install post-git..."
222- $pathToInstall = Split-Path - Path $mergePath - Parent
220+ # Download and install Posh-Git
221+ Write-Host " Download and install posh-git..."
223222 $currentFolder = $pwd
224- cd $pathToInstall
225-
226- # Already exits?
227- if ((Test-Path posh- git) -eq $true )
228- {
229- Write-Host " Already installed - updating..."
230- cd .\posh- git\
231- git pull - q
232- }
233- # First time installation
234- else
235- {
236- git clone https:// github.com / dahlbyk/ posh- git.git - q
237- cd .\posh- git\
238- }
239- .\install.ps1
223+ PowerShellGet\Install-Module posh- git - Scope CurrentUser - Force
240224
241225 cd $currentFolder
242226
You can’t perform that action at this time.
0 commit comments