Sometimes when attempting to create packages with Octopack you may get an error as show below.
“You are trying to build with OctoPack, but the NuGet targets file that OctoPack depends on is not available on this computer. This is probably because the OctoPack package has not been committed to source control, or NuGet Package Restore is not enabled. Please enable NuGet Package Restore to download them”
CAUSE
This error is caused by having a solution with multiple project and referencing octopack. However one or more if these projects has a nuspec file but does not reference octopack or has an older version.
RESOLUTION
Resolving this involves updating the version of the OctoPack library. This is through running the nuget command.
Update-Package OctoPack
All the projects with a reference to the library will have it updated and if any of them is not listed in the process, then install Octopack or remove the nuspec file.