From: AJ ONeal Date: Sat, 4 Jul 2020 07:32:23 +0000 (+0000) Subject: install git if not present X-Git-Url: https://git.josue.xyz/?p=webi-installers%2F.git;a=commitdiff_plain;h=2167a66c0f08a8737e1fab64633296224a6305b6 install git if not present --- diff --git a/golang/install.ps1 b/golang/install.ps1 index 271960a..5649e07 100644 --- a/golang/install.ps1 +++ b/golang/install.ps1 @@ -9,6 +9,11 @@ $pkg_dst = "$Env:USERPROFILE\.local\opt\$pkg_cmd_name" $pkg_dst_cmd = "$pkg_dst\bin\$pkg_cmd_name" $pkg_dst_bin = "$pkg_dst\bin" +if (!(Get-Command "git.exe" -ErrorAction SilentlyContinue)) +{ + & powershell -ExecutionPolicy Bypass "$Env:USERPROFILE\.local\bin\webi.ps1" git +} + # Fetch archive IF (!(Test-Path -Path "$pkg_download")) {