You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
AFAIK, these are the only possible approaches to this (but feel free to correct me if I'm wrong :))
use init.ps1 and instantly install psbuild into the NuGet profile (no uninstall functionality, package can be removed, psbuild will remain available)
use install.ps1 and ´uninstall.ps1` (requires the package to remain installed at least once on the system)
use install.ps1 without a proper uninstall.ps1, same effect as using init.ps1 in the above scenario
don't use any of the above and expose Enable-PSBuild and Disable-PSBuild cmdlets in init.ps1
init.ps1 is called each time the package is loaded (eg during visual studio solution load, or during package install before install.ps1) install.ps1 is called each time the package gets installed
All approaches require checking whether psbuild is already installed or not.
Any preference?
Also, the package should be a developmentOnly package.
Thanks for the comments. This is a bit different from what you are thinking of. Here is the user statement.
As a user I would like to be able to use psbuild for building from the package manage console
In this case the user does not want/need to install the psbuild nuget package. Instead he wants the commands to be made available via the pkg manager console.
Like many other PS hosts the pkg mgr console has its own PS profile. You can see this by printing out the value for $profile from inside the console. The idea here is that if the user invokes the GetPSBuild.psm1 script (see readme.md for directions). Typically this lives in the same folder as the standard PS profile and with the name Nuget_profile.ps1.
The idea is that when the user installs via with the command
When psbuild is installed we should add it to the nuget profile as well that way a VS user can easily use this from the package manager console.
The text was updated successfully, but these errors were encountered: