Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow NuGetRestoreSettings to opt out of setting -NonInteractive #2345

flcdrg opened this Issue Oct 30, 2018 · 1 comment


None yet
3 participants
Copy link

commented Oct 30, 2018

What You Are Seeing?

NuGetRestoreSettings always sets -NonInteractive

What is Expected?

Under certain circumstances, I'd like nuget to not run run with the -NonInteractive parameter - for example when NuGet is run in combination with the Azure Artifacts CredentialProvider.VSS.exe. In that case, when used at an interactive command prompt, I'd want the credential provider to prompt the user for credentials. Currently NuGet passes through the -NonInteractive parameter to CredentialProvider.VSS.exe and so it just fails (rather than prompting the user).

(In my case, I would check System.Environment.UserInteractive to determine whether -NonInteractive should be set or not)

What version of Cake are you using?


Are you running on a 32 or 64 bit system?


What environment are you running on? Windows? Linux? Mac?


Are you running on a CI Server? If so, which one?

TeamCity and Azure Pipelines

How Did You Get This To Happen? (Steps to Reproduce)

  1. Use Azure Artifacts NuGet feed
  2. Copy CredentialProvider.VSS.exe and put it in tools directory (alongside Cake's NuGet.exe)
  3. Use NuGetRestore("myproject.sln") in Cake script
  4. Note that script fails to create authentication token and no user prompt is shown.

@flcdrg flcdrg changed the title Allow NuGetRestoreSettings to opt out of settings -NonInteractive Allow NuGetRestoreSettings to opt out of setting -NonInteractive Oct 30, 2018

flcdrg added a commit to flcdrg/cake that referenced this issue Jan 16, 2019

Add NonInteractive property to NuGetRestoreSettings
- Defaults to true (preserving current behaviour as the default)
- Setting to false means NuGet.exe is free to prompt for user input/confirmation (useful when run interactively and when combined with authorisation providers)

Implements cake-build#2345

@mholo65 mholo65 added the Improvement label Jan 16, 2019

@mholo65 mholo65 added this to the v0.33.0 milestone Jan 16, 2019


This comment has been minimized.

Copy link

commented Jan 16, 2019

Fixed by #2451

@devlead devlead closed this Jan 16, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.