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
When Publish-Module is invoked by this deployment type the path parameter is being used instead of the name param. The path param seems to require a directory and if you give it a directory that does not NOT match the name of your module ( for instance name Src ) or you give it the path to your module's psd1 you'll get errors like below:
Publish-Module : The specified path 'C:\dev\MyRepo\Src\MyModule.psd1' is not a valid directory.
At C:\Program Files\WindowsPowerShell\Modules\PSDeploy\1.0.1\PSDeployScripts\PSGalleryModule.ps1:54 char:9+Publish-Module@params+ ~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidArgument: (...:String) [Publish-Module], ArgumentException
+ FullyQualifiedErrorId : PathIsNotADirectory,Publish-Module
or, if using the Src dir
Publish-Module : The specified module with path 'C:\dev\MyRepo\Src\` was not published because no valid module was found with that path.At C:\Program Files\WindowsPowerShell\Modules\PSDeploy\1.0.1\PSDeployScripts\PSGalleryModule.ps1:54 char:9+ Publish-Module @params+ ~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : InvalidArgument: (..., ArgumentException + FullyQualifiedErrorId : InvalidModulePathToPublish,Publish-Module
I could be missing something but it seems like an easy fix would just be to use name instead of path. The name param will accept a dir path, a name, or a file path. When I make this change locally, things work fine.
Thanks for all your work on this! Love this tool.
The text was updated successfully, but these errors were encountered:
Overview
When
Publish-Module
is invoked by this deployment type thepath
parameter is being used instead of thename
param. Thepath
param seems to require a directory and if you give it a directory that does not NOT match the name of your module ( for instance name Src ) or you give it the path to your module's psd1 you'll get errors like below:or, if using the Src dir
PSDeploy/PSDeploy/PSDeployScripts/PSGalleryModule.ps1
Line 45 in 072a1bf
I could be missing something but it seems like an easy fix would just be to use
name
instead ofpath
. Thename
param will accept a dir path, a name, or a file path. When I make this change locally, things work fine.Thanks for all your work on this! Love this tool.
The text was updated successfully, but these errors were encountered: