mirror of
https://github.com/WarmUpTill/SceneSwitcher.git
synced 2026-03-22 01:44:49 -05:00
Based on OBS plugin template build scripts with some minor adjustments: * Adjust format check scripts to exclude ./deps folder * Adjust release scripts to only draft releases * Always build installers * Always upload build artefacts * Build opencv for Mac and Windows releases
26 lines
698 B
PowerShell
26 lines
698 B
PowerShell
function Check-Git {
|
|
<#
|
|
.SYNOPSIS
|
|
Ensures available git executable on host system.
|
|
.DESCRIPTION
|
|
Checks whether a git command is available on the host system. If none is found,
|
|
Git is installed via winget.
|
|
.EXAMPLE
|
|
Check-Git
|
|
#>
|
|
|
|
if ( ! ( Test-Path function:Log-Info ) ) {
|
|
. $PSScriptRoot/Logger.ps1
|
|
}
|
|
|
|
Log-Information 'Checking for Git executable...'
|
|
|
|
if ( ! ( Get-Command git ) ) {
|
|
Log-Warning 'No Git executable found. Will try to install via winget.'
|
|
winget install git
|
|
} else {
|
|
Log-Debug "Git found at $(Get-Command git)."
|
|
Log-Status "Git found."
|
|
}
|
|
}
|