Tinus EngOps Wiki

Logo

OpsaC - Operating as PowerShell code

Links

Home

PowerShell Blog

PowerShell Index

PowerShell Search

Additional Websites

View my GitHub Profile

View my GitHub Gists

View Tinus IT Wiki

View my Photo Website

Manifest

published: January 29, 2019 author: Tinu tags: PowerShell categories: PowerShell-Class


Table of Contents

Create Manifest

New-ModuleManifest myModule.psd1 -ModuleVersion "0.0.1" -Author "YourNameHere"

Additional Settings

#Script module or binary module file associated with this manifest.
RootModule = 'myModule.psm1'

#Version number of this module.
ModuleVersion = '0.0.1'

# ID used to uniquely identify this module
GUID = '6ac75004-c390-4ae4-aa13-7a0e869c43b1'

# Author of this module
Author = 'Your Name'

# Company or vendor of this module
CompanyName = 'Your Company'

# Copyright statement for this module
Copyright = '(c) 2019 Your Name | Your Company. All rights reserved.'

# Description of the functionality provided by this module
Description = 'Describe  your module here'

# Minimum version of the PowerShell engine required by this module
PowerShellVersion = '5.1'

# Functions to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no functions to export.
FunctionsToExport = @('Get-Function', 'Test-Function', 'Set-Function')

# Private data to pass to the module specified in RootModule/ModuleToProcess. This may also contain a PSData hashtable with additional module metadata used by PowerShell.
PrivateData = @{

    PSData = @{

        # Tags applied to this module. These help with module discovery in online galleries.
        Tags = @()

        # A URL to the license for this module.
        # LicenseUri = ''

        # A URL to the main website for this project.
        ProjectUri = 'Url to the project'

        # A URL to an icon representing this module.
        # IconUri = ''

        # ReleaseNotes of this module
        ReleaseNotes = 'Url to the Changelog'

    } # End of PSData hashtable

} # End of PrivateData hashtable

# HelpInfo URI of this module
HelpInfoURI = 'Url to the Help'

Test Manifest

Test-ModuleManifest myModule.psd1

Test Module

Import-Module .\myModule.psd1

Get-Function

Test-Function

Set-Function

See also

New-ModuleManifest on Microsoft Docs


← Previous Post [ Top ] Copyright © 2024 by tinuwalther [ Blog ] Next Post →