-
Notifications
You must be signed in to change notification settings - Fork 2
/
AutoPkgRelease.nupkg.recipe.yaml
33 lines (32 loc) · 1.63 KB
/
AutoPkgRelease.nupkg.recipe.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
---
# Based upon: https://github.com/autopkg/recipes/blob/master/AutoPkg/AutoPkgGitMaster.nupkg.recipe
Description: Build Chocolatey package for released AutoPkg
Identifier: com.github.jgstew.nupkg.AutoPkg
Input:
NAME: autopkg
PYTHON_PACKAGE_ID: python3
PYTHON_VERSION: "3.10.11"
MinimumVersion: "2.3"
SupportedPlatforms:
- Windows
ParentRecipe: com.github.jgstew.download.AutoPkgReleaseSource
Process:
- Processor: ChocolateyPackager
Arguments:
id: "%NAME%"
version: "%version%"
title: "%NAME%"
authors: Autopkg Contributors
description: AutoPkg is an automation framework software packaging and distribution, oriented towards the tasks one would normally perform manually to prepare third-party software for mass deployment to managed clients.
installer_type: zip
dependencies:
- {"id": "%PYTHON_PACKAGE_ID%", "version": "%PYTHON_VERSION%"}
additional_install_actions: |
$AutoPkgDir = Resolve-Path $env:ChocolateyPackageFolder\tools\autopkg-*
& python -m venv $AutoPkgDir\.python-env
Write-Output 'Running "pip install ..." to generate self-contained environment.'
& $AutoPkgDir\.python-env\Scripts\pip --disable-pip-version-check install -r $AutoPkgDir\gh_actions_requirements.txt --quiet
Get-ChildItem -Recurse $AutoPkgDir\.python-env -Include *.exe, *.dll |
foreach { New-Item -ItemType File "$($_.FullName).ignore" } | Write-Verbose
Install-ChocolateyPowershellCommand -PackageName $packageArgs.packageName -PsFileFullPath $AutoPkgDir\Scripts\autopkg.ps1
# TODO: set output var `nuget_package_path` to ENV for further github action use