Skip to content
Merged
1 change: 0 additions & 1 deletion src/code/FindPSResource.cs
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ public sealed class FindPSResource : PSCmdlet
/// </summary>
[Parameter(Position = 0,
ValueFromPipeline = true,
ValueFromPipelineByPropertyName = true,
ParameterSetName = ResourceNameParameterSet)]
[ValidateNotNullOrEmpty]
public string[] Name { get; set; }
Expand Down
2 changes: 1 addition & 1 deletion src/code/GetInstalledPSResource.cs
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public sealed class GetInstalledPSResource : PSCmdlet
/// <summary>
/// Specifies the desired name for the resource to look for.
/// </summary>
[Parameter(Position = 0, ValueFromPipeline = true, ValueFromPipelineByPropertyName = true)]
[Parameter(Position = 0, ValueFromPipeline = true)]
public string[] Name { get; set; }

/// <summary>
Expand Down
5 changes: 2 additions & 3 deletions src/code/GetPSResourceRepository.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@ namespace Microsoft.PowerShell.PowerShellGet.Cmdlets
/// </summary>

[Cmdlet(VerbsCommon.Get,
"PSResourceRepository",
HelpUri = "<add>")]
"PSResourceRepository")]
public sealed
class GetPSResourceRepository : PSCmdlet
{
Expand All @@ -28,7 +27,7 @@ class GetPSResourceRepository : PSCmdlet
/// Specifies the name(s) of a registered repository to find.
/// Supports wild card characters.
/// </summary>
[Parameter(Position = 0, ValueFromPipeline = true, ValueFromPipelineByPropertyName = true)]
[Parameter(Position = 0, ValueFromPipeline = true)]
[ArgumentCompleter(typeof(RepositoryNameCompleter))]
[ValidateNotNullOrEmpty]
public string[] Name { get; set; } = Utils.EmptyStrArray;
Expand Down
10 changes: 5 additions & 5 deletions src/code/PublishPSResource.cs
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public sealed class PublishPSResource : PSCmdlet
/// Specifies the path to the resource that you want to publish. This parameter accepts the path to the folder that contains the resource.
/// Specifies a path to one or more locations. Wildcards are permitted. The default location is the current directory (.).
/// </summary>
[Parameter(Mandatory = true, Position = 0, ValueFromPipeline = true, ValueFromPipelineByPropertyName = true, ParameterSetName = "PathParameterSet")]
[Parameter(Mandatory = true, Position = 0, ParameterSetName = "PathParameterSet")]
[ValidateNotNullOrEmpty]
public string Path
{
Expand Down Expand Up @@ -80,7 +80,7 @@ public string Path
/// No characters are interpreted as wildcards. If the path includes escape characters, enclose them in single quotation marks.
/// Single quotation marks tell PowerShell not to interpret any characters as escape sequences.
/// </summary>
[Parameter(Mandatory = true, ValueFromPipeline = true, ValueFromPipelineByPropertyName = true, ParameterSetName = "PathLiteralParameterSet")]
[Parameter(Mandatory = true, ParameterSetName = "PathLiteralParameterSet")]
[ValidateNotNullOrEmpty]
public string LiteralPath
{
Expand Down Expand Up @@ -118,7 +118,7 @@ public string LiteralPath
/// <summary>
/// Specifies a proxy server for the request, rather than a direct connection to the internet resource.
/// </summary>
[Parameter(ValueFromPipelineByPropertyName = true)]
[Parameter()]
[ValidateNotNullOrEmpty]
public Uri Proxy {
set
Expand All @@ -135,7 +135,7 @@ public Uri Proxy {
/// <summary>
/// Specifies a user account that has permission to use the proxy server that is specified by the Proxy parameter.
/// </summary>
[Parameter(ValueFromPipelineByPropertyName = true)]
[Parameter()]
[ValidateNotNullOrEmpty]
public PSCredential ProxyCredential {
set
Expand Down Expand Up @@ -163,7 +163,7 @@ public PSCredential ProxyCredential {
protected override void BeginProcessing()
{
// Create a respository story (the PSResourceRepository.xml file) if it does not already exist
// This is to create a better experience for those who have just installed v3 and want to get up and running quickly
// This is to create a better experience for those who have just installed v3 and want to get up and running quickly
RepositorySettings.CheckRepositoryStore();
}

Expand Down
6 changes: 2 additions & 4 deletions src/code/RegisterPSResourceRepository.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
using System;
using System.Collections;
using System.Collections.Generic;
using System.Globalization;
using System.Management.Automation;
using Dbg = System.Diagnostics.Debug;

Expand All @@ -20,8 +19,7 @@ namespace Microsoft.PowerShell.PowerShellGet.Cmdlets
[Cmdlet(VerbsLifecycle.Register,
"PSResourceRepository",
DefaultParameterSetName = NameParameterSet,
SupportsShouldProcess = true,
HelpUri = "<add>")]
SupportsShouldProcess = true)]
public sealed
class RegisterPSResourceRepository : PSCmdlet
{
Expand Down Expand Up @@ -63,7 +61,7 @@ class RegisterPSResourceRepository : PSCmdlet
/// <summary>
/// Specifies a hashtable of repositories and is used to register multiple repositories at once.
/// </summary>
[Parameter(Mandatory = true, ParameterSetName = "RepositoriesParameterSet", ValueFromPipeline = true)]
[Parameter(Mandatory = true, ParameterSetName = RepositoriesParameterSet)]
[ValidateNotNullOrEmpty]
public Hashtable[] Repositories {get; set;}

Expand Down
9 changes: 3 additions & 6 deletions src/code/SetPSResourceRepository.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
using System.Collections;
using System.Collections.Generic;
using Dbg = System.Diagnostics.Debug;
using System.Globalization;
using System.Management.Automation;
using Microsoft.PowerShell.PowerShellGet.UtilClasses;

Expand All @@ -17,8 +16,7 @@ namespace Microsoft.PowerShell.PowerShellGet.Cmdlets
[Cmdlet(VerbsCommon.Set,
"PSResourceRepository",
DefaultParameterSetName = NameParameterSet,
SupportsShouldProcess = true,
HelpUri = "<add>")]
SupportsShouldProcess = true)]
public sealed
class SetPSResourceRepository : PSCmdlet
{
Expand All @@ -35,8 +33,7 @@ class SetPSResourceRepository : PSCmdlet
/// <summary>
/// Specifies the name of the repository to be set.
/// </sumamry>
[Parameter(Mandatory = true, Position = 0, ValueFromPipeline = true,
ValueFromPipelineByPropertyName = true, ParameterSetName = NameParameterSet)]
[Parameter(Mandatory = true, Position = 0, ValueFromPipeline = true, ParameterSetName = NameParameterSet)]
[ArgumentCompleter(typeof(RepositoryNameCompleter))]
[ValidateNotNullOrEmpty]
public string Name { get; set; }
Expand All @@ -51,7 +48,7 @@ class SetPSResourceRepository : PSCmdlet
/// <summary>
/// Specifies a hashtable of repositories and is used to register multiple repositories at once.
/// </summary>
[Parameter(Mandatory = true, ValueFromPipelineByPropertyName = true, ParameterSetName = RepositoriesParameterSet)]
[Parameter(Mandatory = true, ParameterSetName = RepositoriesParameterSet)]
[ValidateNotNullOrEmpty]
public Hashtable[] Repositories { get; set; }

Expand Down
7 changes: 2 additions & 5 deletions src/code/UnregisterPSResourceRepository.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@ namespace Microsoft.PowerShell.PowerShellGet.Cmdlets

[Cmdlet(VerbsLifecycle.Unregister,
"PSResourceRepository",
SupportsShouldProcess = true,
HelpUri = "<add>")]
SupportsShouldProcess = true)]
public sealed
class UnregisterPSResourceRepository : PSCmdlet
{
Expand All @@ -24,9 +23,7 @@ class UnregisterPSResourceRepository : PSCmdlet
/// <summary>
/// Specifies the desired name for the repository to be registered.
/// </summary>
[Parameter(Mandatory= true, Position = 0,
ValueFromPipeline = true,
ValueFromPipelineByPropertyName = true)]
[Parameter(Mandatory= true, Position = 0, ValueFromPipeline = true, ValueFromPipelineByPropertyName = true)]
[ArgumentCompleter(typeof(RepositoryNameCompleter))]
[ValidateNotNullOrEmpty]
public string[] Name { get; set; } = Utils.EmptyStrArray;
Expand Down