Common.ps1


function Get-BoxPath {
  param(
    [string] $Path
  )

  $boxPath = Join-Path $global:HOME ".box"
  if (-not(Test-Path -Path $boxPath -PathType Container)) {
    New-Item -Path $boxPath -ItemType Directory | Out-Null
  }

  if ($Path) {
    $boxPath = Join-Path $boxPath $path
  }

  return $boxPath

}
function Install-Scoop {

  if (-Not(Get-Command "scoop" -ErrorAction SilentlyContinue)) { 
    Write-Host "Installing scoop"
    Invoke-RestMethod -Uri https://get.scoop.sh | Invoke-Expression
  }
}