Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
description: Describes the settings and practices for writing module manifest files.
Locale: en-US
ms.date: 07/07/2023
ms.date: 09/04/2025
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_module_manifests?view=powershell-5.1&WT.mc_id=ps-gethelp
schema: 2.0.0
title: about_Module_Manifests
Expand Down Expand Up @@ -64,6 +64,7 @@ PrivateData = @{
# ProjectUri = ''
# IconUri = ''
# ReleaseNotes = ''
# ExternalModuleDependencies = @()
} # End of PSData hashtable
} # End of PrivateData hashtable
# HelpInfoURI = ''
Expand Down Expand Up @@ -1470,15 +1471,18 @@ The **PSData** child property is used for the following scenarios:

- PowerShell Gallery - When you create a module manifest using
`New-ModuleManifest` the cmdlet prepopulates the **PSData** hashtable with
place holder keys that are needed when publishing the module to the
PowerShell Gallery. For more information on module manifests and the
publishing to the PowerShell Gallery, see
placeholder keys needed when publishing the module to the PowerShell Gallery.
For more information on module manifests and the publishing to the PowerShell
Gallery, see
[Package manifest values that impact the PowerShell Gallery UI][03].
- Crescendo modules - When you export a Crescendo manifest to create a new
module, `Export-CrescendoModule` adds the value `CrescendoBuilt` to the
**PSData.Tags** property. You can use this tag to find modules in the
PowerShell Gallery that were created using Crescendo. For more information,
see [Export-CrescendoModule][15].
- The **PSData.ExternalModuleDependencies** property is an array of module names
that are dependencies for this module. This property is informational only and
doesn't affect module installation or loading.

### HelpInfoURI

Expand Down
21 changes: 13 additions & 8 deletions reference/5.1/Microsoft.PowerShell.Core/New-ModuleManifest.md
Original file line number Diff line number Diff line change
Expand Up @@ -252,8 +252,9 @@ $moduleSettings = @{
New-ModuleManifest @moduleSettings
```

For information about Updatable Help, see [about_Updatable_Help](./About/about_Updatable_Help.md).
For information about the HelpInfo XML file, see [Supporting Updatable Help](/powershell/scripting/developer/module/supporting-updatable-help).
For information about Updatable Help, see [about_Updatable_Help](About/about_Updatable_Help.md).
For information about the HelpInfo XML file, see
[Supporting Updatable Help](/powershell/scripting/developer/module/supporting-updatable-help).

### Example 5 - Getting module information

Expand Down Expand Up @@ -951,8 +952,9 @@ Enter each module name as a string or as a hash table with **ModuleName** and **
keys. The hash table can also have an optional **GUID** key. You can combine strings and hash tables
in the parameter value.

In PowerShell 2.0, `Import-Module` doesn't import required modules automatically. It just verifies
that the required modules are in the global session state.
When you install a module using the `Install-Module` or `Install-PSResource` commands, these
commands check this list. If the required modules aren't installed, the commands attempt to install
required modules.

```yaml
Type: System.Object[]
Expand Down Expand Up @@ -1139,10 +1141,6 @@ that is installed in the global assembly cache.
To add or change files in the `$PSHOME\Modules` directory, start PowerShell with the **Run as
administrator** option.

In PowerShell 2.0, many parameters of `New-ModuleManifest` were mandatory, even though they weren't
required in a module manifest. Beginning in PowerShell 3.0, only the **Path** parameter is
mandatory.

A session is an instance of the PowerShell execution environment. A session can have one or more
session states. By default, a session has only a global session state, but each imported module has
its own session state. Session states allow the commands in a module to run without affecting the
Expand All @@ -1152,6 +1150,13 @@ The caller's session state is the session state into which a module is imported.
refers to the global session state, but when a module imports nested modules, the caller is the
module and the caller's session state is the module's session state.

In PowerShell 2.0, many parameters of `New-ModuleManifest` were mandatory, even though they weren't
required in a module manifest. Beginning in PowerShell 3.0, only the **Path** parameter is
mandatory.

In PowerShell 2.0, `Import-Module` doesn't import required modules automatically. It just verifies
that the required modules are in the global session state.

## RELATED LINKS

[Export-ModuleMember](Export-ModuleMember.md)
Expand Down
69 changes: 37 additions & 32 deletions reference/5.1/Microsoft.PowerShell.Utility/Select-Object.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
external help file: Microsoft.PowerShell.Commands.Utility.dll-Help.xml
Locale: en-US
Module Name: Microsoft.PowerShell.Utility
ms.date: 06/19/2024
ms.date: 09/03/2025
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.utility/select-object?view=powershell-5.1&WT.mc_id=ps-gethelp
schema: 2.0.0
aliases:
Expand Down Expand Up @@ -217,9 +217,9 @@ outputted objects have a specific standard format, the expanded property might n

```powershell
# Create a custom object to use for the Select-Object example.
$object = [pscustomobject]@{Name="CustomObject";Expand=@(1,2,3,4,5)}
$object = [pscustomobject]@{Name="CustomObject";List=@(1,2,3,4,5)}
# Use the ExpandProperty parameter to Expand the property.
$object | Select-Object -ExpandProperty Expand -Property Name
$object | Select-Object -ExpandProperty List -Property Name
```

```Output
Expand All @@ -233,35 +233,14 @@ $object | Select-Object -ExpandProperty Expand -Property Name
```powershell
# The output did not contain the Name property, but it was added successfully.
# Use Get-Member to confirm the Name property was added and populated.
$object | Select-Object -ExpandProperty Expand -Property Name | Get-Member
$object | Select-Object -ExpandProperty List -Property Name | Get-Member -MemberType Properties
```

```Output
TypeName: System.Int32

Name MemberType Definition
---- ---------- ----------
CompareTo Method int CompareTo(System.Object value), int CompareTo(int value), ...
Equals Method bool Equals(System.Object obj), bool Equals(int obj), bool IEq...
GetHashCode Method int GetHashCode()
GetType Method type GetType()
GetTypeCode Method System.TypeCode GetTypeCode(), System.TypeCode IConvertible.Ge...
ToBoolean Method bool IConvertible.ToBoolean(System.IFormatProvider provider)
ToByte Method byte IConvertible.ToByte(System.IFormatProvider provider)
ToChar Method char IConvertible.ToChar(System.IFormatProvider provider)
ToDateTime Method datetime IConvertible.ToDateTime(System.IFormatProvider provider)
ToDecimal Method decimal IConvertible.ToDecimal(System.IFormatProvider provider)
ToDouble Method double IConvertible.ToDouble(System.IFormatProvider provider)
ToInt16 Method int16 IConvertible.ToInt16(System.IFormatProvider provider)
ToInt32 Method int IConvertible.ToInt32(System.IFormatProvider provider)
ToInt64 Method long IConvertible.ToInt64(System.IFormatProvider provider)
ToSByte Method sbyte IConvertible.ToSByte(System.IFormatProvider provider)
ToSingle Method float IConvertible.ToSingle(System.IFormatProvider provider)
ToString Method string ToString(), string ToString(string format), string ToS...
ToType Method System.Object IConvertible.ToType(type conversionType, System...
ToUInt16 Method uint16 IConvertible.ToUInt16(System.IFormatProvider provider)
ToUInt32 Method uint32 IConvertible.ToUInt32(System.IFormatProvider provider)
ToUInt64 Method uint64 IConvertible.ToUInt64(System.IFormatProvider provider)
Name NoteProperty string Name=CustomObject
```

Expand Down Expand Up @@ -425,6 +404,30 @@ name children
USA @{name=Southwest}
```

### Example 15: Use wildcards with the -ExpandProperty parameter

This example demonstrates using wildcards with the **ExpandProperty** parameter. The wildcard
character must resolve to a single property name. If the wildcard character resolves to more than
one property name, `Select-Object` returns an error.

```powershell
# Create a custom object.
$object = [pscustomobject]@{
Label = "MyObject"
Names = @("John","Jane","Joe")
Numbers = @(1,2,3,4,5)
}
# Try to expand multiple properties using a wildcard.
$object | Select-Object -ExpandProperty N*
Select-Object: Multiple properties cannot be expanded.

# Use a wildcard that resolves to a single property.
$object | Select-Object -ExpandProperty Na*
John
Jane
Joe
```

## PARAMETERS

### -ExcludeProperty
Expand All @@ -448,17 +451,19 @@ Accept wildcard characters: True

Specifies a property to select, and indicates that an attempt should be made to expand that
property. If the input object pipeline doesn't have the property named, `Select-Object` returns an
error.
error. This parameter supports wildcards. However, the wildcard character must resolve to a single
property name. If the wildcard character resolves to more than one property name, `Select-Object`
returns an error.

When you use **ExpandProperty**, `Select-Object` attempts to expand the specified property for every

- If the specified property is an array, each value of the array is included in the output.
- If the specified property is an object, the objects properties are expanded for every
**InputObject**

In either case, the output objects' **Type** matches the expanded property's **Type**.

> [!NOTE]
> There is a side-effect when using **ExpandProperty**. The `Select-Object` adds the selected
> properties to the original object as **NoteProperty** members.
In either case, the output objects' **Type** matches the expanded property's **Type**. There is a
side-effect when using **ExpandProperty**. The `Select-Object` adds the selected properties to the
original object as **NoteProperty** members.

If the **Property** parameter is specified, `Select-Object` attempts to add each selected property
as a **NoteProperty** to every outputted object.
Expand All @@ -481,7 +486,7 @@ Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Accept wildcard characters: True
```

### -First
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
description: Describes the settings and practices for writing module manifest files.
Locale: en-US
ms.date: 07/07/2023
ms.date: 09/04/2025
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_module_manifests?view=powershell-7.4&WT.mc_id=ps-gethelp
schema: 2.0.0
title: about_Module_Manifests
Expand Down Expand Up @@ -64,6 +64,7 @@ PrivateData = @{
# ProjectUri = ''
# IconUri = ''
# ReleaseNotes = ''
# ExternalModuleDependencies = @()
} # End of PSData hashtable
} # End of PrivateData hashtable
# HelpInfoURI = ''
Expand Down Expand Up @@ -1470,9 +1471,9 @@ The **PSData** child property is used for the following scenarios:

- PowerShell Gallery - When you create a module manifest using
`New-ModuleManifest` the cmdlet prepopulates the **PSData** hashtable with
place holder keys that are needed when publishing the module to the
PowerShell Gallery. For more information on module manifests and the
publishing to the PowerShell Gallery, see
placeholder keys needed when publishing the module to the PowerShell Gallery.
For more information on module manifests and the publishing to the PowerShell
Gallery, see
[Package manifest values that impact the PowerShell Gallery UI][03].
- Experimental features - Metadata about an experimental feature is kept in the
**ExperimentalFeatures** property of **PSData**. The **ExperimentalFeatures**
Expand All @@ -1484,6 +1485,9 @@ The **PSData** child property is used for the following scenarios:
**PSData.Tags** property. You can use this tag to find modules in the
PowerShell Gallery that were created using Crescendo. For more information,
see [Export-CrescendoModule][15].
- The **PSData.ExternalModuleDependencies** property is an array of module names
that are dependencies for this module. This property is informational only and
doesn't affect module installation or loading.

### HelpInfoURI

Expand Down
53 changes: 34 additions & 19 deletions reference/7.4/Microsoft.PowerShell.Core/New-ModuleManifest.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
external help file: System.Management.Automation.dll-Help.xml
Locale: en-US
Module Name: Microsoft.PowerShell.Core
ms.date: 12/09/2022
ms.date: 09/04/2025
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/new-modulemanifest?view=powershell-7.4&WT.mc_id=ps-gethelp
schema: 2.0.0
title: New-ModuleManifest
Expand Down Expand Up @@ -121,10 +121,12 @@ Copyright = '(c) ContosoAdmin. All rights reserved.'
# Minimum version of the PowerShell host required by this module
# PowerShellHostVersion = ''

# Minimum version of Microsoft .NET Framework required by this module. This prerequisite is valid for the PowerShell Desktop edition only.
# Minimum version of Microsoft .NET Framework required by this module. This prerequisite
# is valid for the PowerShell Desktop edition only.
# DotNetFrameworkVersion = ''

# Minimum version of the common language runtime (CLR) required by this module. This prerequisite is valid for the PowerShell Desktop edition only.
# Minimum version of the common language runtime (CLR) required by this module. This
# prerequisite is valid for the PowerShell Desktop edition only.
# CLRVersion = ''

# Processor architecture (None, X86, Amd64) required by this module
Expand All @@ -136,7 +138,8 @@ Copyright = '(c) ContosoAdmin. All rights reserved.'
# Assemblies that must be loaded prior to importing this module
# RequiredAssemblies = @()

# Script files (.ps1) that are run in the caller's environment prior to importing this module.
# Script files (.ps1) that are run in the caller's environment prior to importing this
# module.
# ScriptsToProcess = @()

# Type files (.ps1xml) to be loaded when importing this module
Expand All @@ -148,16 +151,19 @@ Copyright = '(c) ContosoAdmin. All rights reserved.'
# Modules to import as nested modules of the module specified in RootModule/ModuleToProcess
# NestedModules = @()

# 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.
# 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 = @()

# Cmdlets 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 cmdlets to export.
# Cmdlets 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 cmdlets to export.
CmdletsToExport = @()

# Variables to export from this module
VariablesToExport = '*'

# Aliases 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 aliases to export.
# Aliases 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 aliases to export.
AliasesToExport = @()

# DSC resources to export from this module
Expand All @@ -169,7 +175,8 @@ AliasesToExport = @()
# List of all files packaged with this module
# FileList = @()

# 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.
# 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 = @{
Expand Down Expand Up @@ -205,7 +212,8 @@ PrivateData = @{
# HelpInfo URI of this module
# HelpInfoURI = ''

# Default prefix for commands exported from this module. Override the default prefix using Import-Module -Prefix.
# Default prefix for commands exported from this module. Override the default prefix
# using Import-Module -Prefix.
# DefaultCommandPrefix = ''

}
Expand Down Expand Up @@ -265,8 +273,9 @@ $moduleSettings = @{
New-ModuleManifest @moduleSettings
```

For information about Updatable Help, see [about_Updatable_Help](./About/about_Updatable_Help.md).
For information about the HelpInfo XML file, see [Supporting Updatable Help](/powershell/scripting/developer/module/supporting-updatable-help).
For information about Updatable Help, see [about_Updatable_Help](About/about_Updatable_Help.md).
For information about the HelpInfo XML file, see
[Supporting Updatable Help](/powershell/scripting/developer/module/supporting-updatable-help).

### Example 5 - Getting module information

Expand Down Expand Up @@ -549,7 +558,9 @@ Accept wildcard characters: True

### -ExternalModuleDependencies

A list of external modules that this module is depends on.
A list of external modules that this module is depends on. This list is only used to document the
module's dependencies and is not enforced by PowerShell. It's not used by the PowerShellGet or
PSResourceGet commands, or by the PowerShell Gallery.

```yaml
Type: System.String[]
Expand Down Expand Up @@ -608,7 +619,7 @@ Specifies the functions that the module exports. Wildcards are permitted.
You can use this parameter to restrict the functions that are exported by the module. It can remove
functions from the list of exported aliases, but it can't add functions to the list.

If you omit this parameter, `New-ModuleManifest` creates an **FunctionsToExport** key with a value
If you omit this parameter, `New-ModuleManifest` creates a **FunctionsToExport** key with a value
of `*` (all), meaning that all functions defined in the module are exported by the manifest.

```yaml
Expand Down Expand Up @@ -1000,8 +1011,9 @@ Enter each module name as a string or as a hash table with **ModuleName** and **
keys. The hash table can also have an optional **GUID** key. You can combine strings and hash tables
in the parameter value.

In PowerShell 2.0, `Import-Module` doesn't import required modules automatically. It just verifies
that the required modules are in the global session state.
When you install a module using the `Install-Module` or `Install-PSResource` commands, these
commands check this list. If the required modules aren't installed, the commands attempt to install
required modules.

```yaml
Type: System.Object[]
Expand Down Expand Up @@ -1211,10 +1223,6 @@ administrator** option.
> and the error is ignored. All managed DLLs are loaded in the process. This behavior was removed in
> PowerShell 7.1.

In PowerShell 2.0, many parameters of `New-ModuleManifest` were mandatory, even though they weren't
required in a module manifest. Beginning in PowerShell 3.0, only the **Path** parameter is
mandatory.

A session is an instance of the PowerShell execution environment. A session can have one or more
session states. By default, a session has only a global session state, but each imported module has
its own session state. Session states allow the commands in a module to run without affecting the
Expand All @@ -1224,6 +1232,13 @@ The caller's session state is the session state into which a module is imported.
refers to the global session state, but when a module imports nested modules, the caller is the
module and the caller's session state is the module's session state.

In PowerShell 2.0, many parameters of `New-ModuleManifest` were mandatory, even though they weren't
required in a module manifest. Beginning in PowerShell 3.0, only the **Path** parameter is
mandatory.

In PowerShell 2.0, `Import-Module` doesn't import required modules automatically. It just verifies
that the required modules are in the global session state.

## RELATED LINKS

[Export-ModuleMember](Export-ModuleMember.md)
Expand Down
Loading
Loading