I want to organize functions into multiple .psm1 files and have them loaded by a single Module Manifest file (.psd1) -- such that Only the .psd1 file would need to have the same name as the module.
I think it should be possible. Can anyone help me out please ?
PSD1 files are manifests and only matter when you make a module "ModuleName" in a folder named "ModuleName" with the 2 files "modulename. psd1" and "modulename. psm1". The PSD1 manifest can be created using the New-ModuleManifest cmdlet.
A module manifest is a PowerShell data file ( . psd1 ) that describes the contents of a module and determines how a module is processed. The manifest file is a text file that contains a hash table of keys and values.
Installing PowerShell modules from the PowerShell Gallery is the easiest way to install modules. To install a package or module from the Gallery, we use the command: Install-Module or Install-Script cmdlet, depending on the package type.
New-ModuleManifest
commandModulepath\Modulename.psm1
Import-Module <<module-name>>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With