tag:help.appveyor.com,2012-11-13:/discussions/questions/34356-multiple-nuget-deployments-based-on-branchAppVeyor: Discussion 2019-04-13T21:01:16Ztag:help.appveyor.com,2012-11-13:Comment/469416322019-02-10T23:27:19Z2019-02-10T23:27:19ZMultiple Nuget Deployments based on Branch<div><p>note: the reason I want this all under one project is so that I can share the build number.</p></div>chase.florelltag:help.appveyor.com,2012-11-13:Comment/469416322019-02-11T08:48:41Z2019-02-11T08:48:41ZMultiple Nuget Deployments based on Branch<div><p>You can add two Nuget deployments, one target Nuget, another Myget (Nuget deployment with <code>Server URL</code> specific to Myget). Then use <a href="https://www.appveyor.com/docs/deployment/#conditional-deployment">conditional deployment</a> to setup which branch deploy to which deployment.</p>
<p>Regarding <code>-pre</code> prefix is it about file name? As I understand <code>.nupkg</code> files are being created with <code>build.ps1</code> script, so you can use <code>APPVEYOR_REPO_BRANCH</code> <a href="https://www.appveyor.com/docs/environment-variables/">environment variable</a> in script to rename <code>.nupkg</code> files when needed, e.g. add <code>-pre</code> prefix when <code>APPVEYOR_REPO_BRANCH</code> equal <code>development</code>.</p>
<p>Hope I understood your questions correctly. If not, please elaborate.</p></div>Ilya Finkelshteyn