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,6 +1,6 @@
---
description: This article contains release notes for the PSResourceGet module.
ms.date: 01/31/2024
ms.date: 10/22/2024
ms.topic: release-notes
title: What's new in PSResourceGet?
---
Expand All @@ -9,12 +9,13 @@ title: What's new in PSResourceGet?
This is a summary of changes to the **Microsoft.PowerShell.PSResourceGet** module. For a more
complete list of changes, see the [CHANGELOG][01] in the GitHub repository.

- Current preview: **Microsoft.PowerShell.PSResourceGet** v1.1.0-preview2
- Current preview: **Microsoft.PowerShell.PSResourceGet** v1.1.0-rc1
- Current stable release: **Microsoft.PowerShell.PSResourceGet** v1.0.5

## Release history

- v1.1.0-preview2 - Current preview release - released to the PowerShell Gallery only
- v1.1.0-rc1 - Current preview release - first shipped in PowerShell 7.5.0-rc1
- v1.1.0-preview2 - released to the PowerShell Gallery only
- v1.1.0-preview.1 - Preview release - first shipped in PowerShell 7.5.0-preview.4
- v1.0.5 - first shipped in PowerShell 7.5.0-preview.3
- v1.0.4.1 - first shipped in PowerShell 7.4.2
Expand All @@ -26,6 +27,14 @@ complete list of changes, see the [CHANGELOG][01] in the GitHub repository.

## Release notes

### v1.1.0-rc1 - 2024-10-24

- Added Group Policy support
- Fix package name matching in local repositories
- `Compress-PSResource -PassThru` now return **FileInfo** instead of string
- Add `AcceptLicense` to `Save-PSResource`
- Other minor bug fixes and improvements

### v1.1.0-preview2 - 2024-09-13

- New cmdlet `Compress-PSResource` to create a `.nupkg` package without publishing it to a repository
Expand Down
Original file line number Diff line number Diff line change
@@ -1,17 +1,18 @@
---
description: Describes how to use version 3.x of the PowerShellGet module.
Locale: en-US
ms.custom: 1.0.5
ms.date: 05/17/2024
ms.custom: 1.1.0-rc1
ms.date: 10/22/2024
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.psresourceget/about_PSResourceGet?view=powershellget-3.x&WT.mc_id=ps-gethelp
schema: 2.0.0
title: about PSResourceGet
---
# about_PSResourceGet

## Short description
Describes how to use version 1.1.0-preview2 of the **Microsoft.PowerShell.PSResourceGet**
module.

Describes how to use version 1.1.0-rc1 of the
**Microsoft.PowerShell.PSResourceGet** module.

## Long description

Expand All @@ -32,8 +33,7 @@ This version of PowerShellGet focuses on a few key areas:

Previous versions of **PowerShellGet** had separate commands to work with
modules and scripts. In **Microsoft.PowerShell.PSResourceGet**, all packages in
the PowerShell Gallery are defined as **PSResource** objects. This reduces the
number of cmdlets from 26 in version 2.x to 18 in version 0.9.
the PowerShell Gallery are defined as **PSResource** objects.

The following table shows the cmdlets that are available in **PowerShellGet**
v3 and their v2 equivalents.
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
---
description: Describes the Group Policy settings for PowerShell
Locale: en-US
ms.custom: 1.1.0-rc1
ms.date: 10/22/2024
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_psresourceget_group_policy?view=powershellget-3.x&WT.mc_id=ps-gethelp
schema: 2.0.0
title: about_PSResourceGet_Group_Policy
---
# about_PSResourceGet_Group_Policy

## Short description

Describes the Group Policy settings for the PSResourceGet module.

## Long description

**Microsoft.PowerShell.PSResourceGet** includes a Group Policy to specify a
list of repositories that can be accessed by the module. All other repositories
are blocked.

Support for Group Policy was added in **Microsoft.PowerShell.PSResourceGet**
v1.1.0-rc1.

The PowerShell Group Policy settings are in the following Group Policy path:

```
User Configuration\
Administrative Templates\
PSResourceGet Repository Policies
```

There is no computer configuration path for these settings.

**Microsoft.PowerShell.PSResourceGet** includes Group Policy templates and an
installation script in module install location.

Group Policy tools use administrative template files (`.admx`, `.adml`) to
populate policy settings in the user interface. This allows administrators to
manage registry-based policy settings. To install the administrative template,
run the `InstallPSResourceGetPolicyDefinitions.ps1` script from an elevated
PowerShell session. The following example shows the location of the script and
template files.

```powershell
$modulePath = Split-Path (Get-Module -Name Microsoft.PowerShell.PSResourceGet).Path
Get-ChildItem -Path $modulePath\*.adm*, $modulePath\*.ps1
```

```Output
Directory: C:\Program Files\PowerShell\Modules\Microsoft.PowerShell.PSResourceGet\1.1.0

Mode LastWriteTime Length Name
---- ------------- ------ ----
-a--- 10/22/2024 3:48 PM 1364 PSResourceRepository.adml
-a--- 10/22/2024 3:48 PM 1839 PSResourceRepository.admx
-a--- 10/22/2024 3:48 PM 2869 InstallPSResourceGetPolicyDefinitions.ps1
```

After installing the templates, you can edit these settings in the Group Policy
Editor (`gpedit.msc`).

## Configure a list of allowed repositories

There is only one setting for the **PSResourceGet Repository Policies** Group
Policy.

1. Open the Group Policy Editor (`gpedit.msc`)
1. Locate the policy under **User configuration** -> **Administrative
Templates** -> **Windows Components** -> **PSResourceGet Repository
Policies**
1. Open the **PSResourceGet Repository Policy** setting
1. Select **Enabled**
1. Select **Show**
1. Add repository in the format:
`Name=PSGallery;Uri=https://www.powershellgallery.com/api/v2`

> [!NOTE]
> Don't use quote characters around the values. Separate the key-value pairs
> with a semicolon (`;`) only.

You may add as may repositories as you like, each on their own line.

> [!CAUTION]
> If you enable the policy without defining any repositories then no
> repositories are allowed, effectively disabling
> **Microsoft.PowerShell.PSResourceGet** module.

## Determine the affect of Group Policy

Once you have applied the Group Policy setting, the PSResourceGet commands that
communicate with repositories check the policy before attempting to access the
repository. If the a specified repository isn't in the allow list, you receive
and error message similar to:

> Repository 'RepoName' is not allowed by Group Policy.

Adding repositories to the allow list doesn't register them for the user. You
must use add the repositories using the `Register-PSResourceRepository` cmdlet.
The `Register-PSResourceRepository` cmdlet doesn't access the repository at
registration time. You won't receive an error if the repository isn't in the
allow list until you try to access the repository.

You can use the following command to determine the repositories that are
allowed by Group Policy:

```powershell
Get-PSResourceRepository | Where-Object { $_.IsAllowedByPolicy }
```
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
external help file: Microsoft.PowerShell.PSResourceGet.dll-Help.xml
Module Name: Microsoft.PowerShell.PSResourceGet
ms.custom: 1.1.0-preview2
ms.date: 09/16/2024
ms.custom: 1.1.0-rc1
ms.date: 10/22/2024
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.psresourceget/compress-psresource?view=powershellget-3.x&WT.mc_id=ps-gethelp
schema: 2.0.0
---
Expand All @@ -16,8 +16,8 @@ Compresses a specified folder containing module or script resources into a `.nup
## SYNTAX

```
Compress-PSResource [-Path] <String> [-DestinationPath] <String> [-PassThru] [-SkipModuleManifestValidate]
[-WhatIf] [-Confirm] [<CommonParameters>]
Compress-PSResource [-Path] <String> [-DestinationPath] <String> [-PassThru]
[-SkipModuleManifestValidate] [-WhatIf] [-Confirm] [<CommonParameters>]
```

## DESCRIPTION
Expand Down Expand Up @@ -150,10 +150,10 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable

## OUTPUTS

### System.String
### System.IO.FileSystemInfo

By default, this command doesn't write any output to the pipeline. When you use the **PassThru**
parameter, it returns full path of the `.nupkg` that was created.
parameter, it returns a **FileSystemInfo** object for the new `.nupkg` file.

## NOTES

Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
external help file: Microsoft.PowerShell.PSResourceGet.dll-Help.xml
Module Name: Microsoft.PowerShell.PSResourceGet
ms.custom: 1.1.0-preview2
ms.date: 09/16/2024
ms.custom: 1.1.0-rc1
ms.date: 10/22/2024
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.psresourceget/find-psresource?view=powershellget-3.x&WT.mc_id=ps-gethelp
schema: 2.0.0
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
external help file: Microsoft.PowerShell.PSResourceGet.dll-Help.xml
Module Name: Microsoft.PowerShell.PSResourceGet
ms.custom: 1.1.0-preview2
ms.date: 09/16/2024
ms.custom: 1.1.0-rc1
ms.date: 10/22/2024
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.psresourceget/get-installedpsresource?view=powershellget-3.x&WT.mc_id=ps-gethelp
schema: 2.0.0
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
external help file: Microsoft.PowerShell.PSResourceGet.dll-Help.xml
Module Name: Microsoft.PowerShell.PSResourceGet
ms.custom: 1.1.0-preview2
ms.date: 09/16/2024
ms.custom: 1.1.0-rc1
ms.date: 10/22/2024
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.psresourceget/get-psresourcerepository?view=powershellget-3.x&WT.mc_id=ps-gethelp
schema: 2.0.0
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
external help file: Microsoft.PowerShell.PSResourceGet.dll-Help.xml
Module Name: Microsoft.PowerShell.PSResourceGet
ms.custom: 1.1.0-preview2
ms.date: 09/16/2024
ms.custom: 1.1.0-rc1
ms.date: 10/22/2024
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.psresourceget/get-psscriptfileinfo?view=powershellget-3.x&WT.mc_id=ps-gethelp
schema: 2.0.0
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
external help file: Microsoft.PowerShell.PSResourceGet.dll-help.xml
Module Name: Microsoft.PowerShell.PSResourceGet
ms.custom: 1.1.0-preview2
ms.date: 09/16/2024
ms.custom: 1.1.0-rc1
ms.date: 10/22/2024
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.psresourceget/import-psgetrepository?view=powershellget-3.x&WT.mc_id=ps-gethelp
schema: 2.0.0
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
external help file: Microsoft.PowerShell.PSResourceGet.dll-Help.xml
Module Name: Microsoft.PowerShell.PSResourceGet
ms.custom: 1.1.0-preview2
ms.date: 09/16/2024
ms.custom: 1.1.0-rc1
ms.date: 10/22/2024
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.psresourceget/install-psresource?view=powershellget-3.x&WT.mc_id=ps-gethelp
schema: 2.0.0
---
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ Help Version: 3.0.24260
Locale: en-US
Module Guid: e4e0bda1-0703-44a5-b70d-8fe704cd0643
Module Name: Microsoft.PowerShell.PSResourceGet
ms.custom: 1.1.0-preview2
ms.date: 09/16/2024
ms.custom: 1.1.0-rc1
ms.date: 10/22/2024
schema: 2.0.0
title: Microsoft.PowerShell.PSResourceGet
---
Expand All @@ -16,7 +16,7 @@ title: Microsoft.PowerShell.PSResourceGet
PSResourceGet is a module with commands for discovering, installing, updating and publishing
PowerShell artifacts like Modules, DSC Resources, Role Capabilities, and Scripts.

This documentation covers the latest version **Microsoft.PowerShell.PSResourceGet** v1.1.0-preview2.
This documentation covers the latest version **Microsoft.PowerShell.PSResourceGet** v1.1.0-rc1.
For a list of differences between versions, see the
[What's new in PSResourceGet?](/powershell/gallery/powershellget/psresourceget-release-notes).

Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
external help file: Microsoft.PowerShell.PSResourceGet.dll-Help.xml
Module Name: Microsoft.PowerShell.PSResourceGet
ms.custom: 1.1.0-preview2
ms.date: 09/16/2024
ms.custom: 1.1.0-rc1
ms.date: 10/22/2024
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.psresourceget/new-psscriptfileinfo?view=powershellget-3.x&WT.mc_id=ps-gethelp
schema: 2.0.0
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
external help file: Microsoft.PowerShell.PSResourceGet.dll-Help.xml
Module Name: Microsoft.PowerShell.PSResourceGet
ms.custom: 1.1.0-preview2
ms.date: 09/16/2024
ms.custom: 1.1.0-rc1
ms.date: 10/22/2024
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.psresourceget/publish-psresource?view=powershellget-3.x&WT.mc_id=ps-gethelp
schema: 2.0.0
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
external help file: Microsoft.PowerShell.PSResourceGet.dll-Help.xml
Module Name: Microsoft.PowerShell.PSResourceGet
ms.custom: 1.1.0-preview2
ms.date: 09/16/2024
ms.custom: 1.1.0-rc1
ms.date: 10/22/2024
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.psresourceget/register-psresourcerepository?view=powershellget-3.x&WT.mc_id=ps-gethelp
schema: 2.0.0
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
external help file: Microsoft.PowerShell.PSResourceGet.dll-Help.xml
Module Name: Microsoft.PowerShell.PSResourceGet
ms.custom: 1.1.0-preview2
ms.date: 09/16/2024
ms.custom: 1.1.0-rc1
ms.date: 10/22/2024
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.psresourceget/save-psresource?view=powershellget-3.x&WT.mc_id=ps-gethelp
schema: 2.0.0
---
Expand Down Expand Up @@ -121,6 +121,42 @@ Accept pipeline input: False
Accept wildcard characters: False
```

### -Quiet

Suppresses the progress bar output.

This parameter was added in PSResourceGet 1.1.0-rc1.

```yaml
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
```

### -AcceptLicense

For modules that require a license, automatically accepts the license agreement during installation.

This parameter was added in PSResourceGet 1.1.0-rc1.

```yaml
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
```

### -Credential

Optional credentials used when accessing a repository.
Expand Down
Loading
Loading