Package creation template and scoop package

Set-MyPackage has a template option that will create skelaton content
when a new package is created.
Add scoop package, so that refresh will occur automatically on
powershell launch if it hasn't been run in the past 3 hours.
This commit is contained in:
Gal Szkolnik 2021-02-07 13:32:23 -05:00
parent 4ba9a69fb9
commit 1672c384ad
4 changed files with 40 additions and 4 deletions

View file

@ -23,7 +23,9 @@ class Packagesz { #: System.Management.Automation.IValidateSetValuesGenerator {
$local:valid = $Package.Condition[0].Logic -notin ([szLogic]::or, [szLogic]::ornot)
$local:currentSys = [SystemName]::_GetValidValues('',$true,$true);
$local:hostname = $(hostname)
$local:username = $( if( $env:USER ) { $env:USER } else { $env:USERNAME })
$local:username = $( if( $env:USER ) { $env:USER } else { $env:USERNAME } )
foreach( $local:c in $Package.Condition ) {
if( $valid -eq ($c.Logic -in ([szLogic]::or, [szLogic]::ornot )) ) { continue }