Introduction
Aim: define output directory for automatically created Chocolatey packages by ketarin to avoid that automatically created nuspec packages will be pushed to GitHub
The steps located in this manual have been followed to create a Chocolatey Packages automatically. One of the steps is to specify the path to the directory where the Automatic Chocolatey Package templates reside. These Packages are maintained in a GitHub repository which have been cloned on the computer.
chocopkgup.exe.config
<?xml version="1.0"?>
<configuration>
<appSettings>
<add key="PackagesFolder" value="C:\path\to\chocolateyautomatic"/>
<add key="TokenReplaceFileSearchPattern" value="*.txt|*.nuspec|*.ps1|*.config"/>
<add key="PS1FileToExecute" value="ChocoPkgUp.ps1"/>
</appSettings>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0"/>
</startup>
</configuration>
A Windows Scheduled task to run ketarin.exe every hour has been created. According the log the nuspec package is created in the directory C:\path\to\chocolateyautomatic\output
which is defined as PackagesFolder
in the chocopkgup.exe.config
file.
chocolatey.package.updater.log
2014-06-14 19:05:01,884 [INFO ] - Attempting to build package from 'packagename.nuspec'.
Successfully created package 'C:\path\to\chocolateyautomatic\_output\packagename\packageversion\packagename.packageversion.nupkg'.
To avoid that the Automatically created Chocolatey packages will be seen as changes to be committed if git status
will be executed, another output
path for automatically created Chocolatey Packages would like to be defined in the chocopkgup.exe.config
Question
How to change output directory of automatically created Chocolatey Packages by ketarin to avoid that the created nuspec packages are created in GitHub checkout?
Although not a direct answer to your question, can you not simply change the .gitignore file to exclude those files and folders?
This is what I have done here:
https://github.com/chocolatey/chocolatey-coreteampackages/blob/master/.gitignore
Hope that helps!
Gary