是否存在列出 PowerShell 项目所需的 powershell 模块的现有约定?相当于Python的requirements.txt或Node的package.json等?运行命令 X 来“安装模块”所有要求?
PowerShell modules 通过其 module manifest 指定其依赖项。
PowerShell 模块通常是独立的,即与其依赖项捆绑在一起。
但是,内部存储库依赖项(在其他模块上)可以通过
RequiredModules
条目指定,并且当您使用过时的Install-Module
命令或其后继者Install-PSResource
时,应该自动安装 - 请参阅此答案了解更多信息。