forked from Azure/azure-powershell
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add error for custom cmdlet when file too big
- Loading branch information
1 parent
e2cc76e
commit 07ace3d
Showing
8 changed files
with
359 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,199 @@ | ||
--- | ||
external help file: | ||
Module Name: Az.Support | ||
online version: https://learn.microsoft.com/powershell/module/az.support/new-azsupportfile | ||
schema: 2.0.0 | ||
--- | ||
|
||
# New-AzSupportFile | ||
|
||
## SYNOPSIS | ||
Creates a new file under a workspace for the specified subscription. | ||
|
||
## SYNTAX | ||
|
||
``` | ||
New-AzSupportFile -Name <String> -WorkspaceName <String> [-SubscriptionId <String>] [-ChunkSize <Single>] | ||
[-FileSize <Single>] [-NumberOfChunk <Single>] [-DefaultProfile <PSObject>] [-Confirm] [-WhatIf] | ||
[<CommonParameters>] | ||
``` | ||
|
||
## DESCRIPTION | ||
Creates a new file under a workspace for the specified subscription. | ||
|
||
## EXAMPLES | ||
|
||
### Example 1: {{ Add title here }} | ||
```powershell | ||
{{ Add code here }} | ||
``` | ||
|
||
```output | ||
{{ Add output here (remove the output block if the example doesn't have an output) }} | ||
``` | ||
|
||
{{ Add description here }} | ||
|
||
### Example 2: {{ Add title here }} | ||
```powershell | ||
{{ Add code here }} | ||
``` | ||
|
||
```output | ||
{{ Add output here (remove the output block if the example doesn't have an output) }} | ||
``` | ||
|
||
{{ Add description here }} | ||
|
||
## PARAMETERS | ||
|
||
### -ChunkSize | ||
Size of each chunk | ||
|
||
```yaml | ||
Type: System.Single | ||
Parameter Sets: (All) | ||
Aliases: | ||
|
||
Required: False | ||
Position: Named | ||
Default value: None | ||
Accept pipeline input: False | ||
Accept wildcard characters: False | ||
``` | ||
### -DefaultProfile | ||
The DefaultProfile parameter is not functional. | ||
Use the SubscriptionId parameter when available if executing the cmdlet against a different subscription. | ||
```yaml | ||
Type: System.Management.Automation.PSObject | ||
Parameter Sets: (All) | ||
Aliases: AzureRMContext, AzureCredential | ||
|
||
Required: False | ||
Position: Named | ||
Default value: None | ||
Accept pipeline input: False | ||
Accept wildcard characters: False | ||
``` | ||
### -FileSize | ||
Size of the file to be uploaded | ||
```yaml | ||
Type: System.Single | ||
Parameter Sets: (All) | ||
Aliases: | ||
|
||
Required: False | ||
Position: Named | ||
Default value: None | ||
Accept pipeline input: False | ||
Accept wildcard characters: False | ||
``` | ||
### -Name | ||
File name. | ||
```yaml | ||
Type: System.String | ||
Parameter Sets: (All) | ||
Aliases: FileName | ||
|
||
Required: True | ||
Position: Named | ||
Default value: None | ||
Accept pipeline input: False | ||
Accept wildcard characters: False | ||
``` | ||
### -NumberOfChunk | ||
Number of chunks to be uploaded | ||
```yaml | ||
Type: System.Single | ||
Parameter Sets: (All) | ||
Aliases: | ||
|
||
Required: False | ||
Position: Named | ||
Default value: None | ||
Accept pipeline input: False | ||
Accept wildcard characters: False | ||
``` | ||
### -SubscriptionId | ||
Azure subscription Id. | ||
```yaml | ||
Type: System.String | ||
Parameter Sets: (All) | ||
Aliases: | ||
|
||
Required: False | ||
Position: Named | ||
Default value: (Get-AzContext).Subscription.Id | ||
Accept pipeline input: False | ||
Accept wildcard characters: False | ||
``` | ||
### -WorkspaceName | ||
File workspace name. | ||
```yaml | ||
Type: System.String | ||
Parameter Sets: (All) | ||
Aliases: FileWorkspaceName | ||
|
||
Required: True | ||
Position: Named | ||
Default value: None | ||
Accept pipeline input: False | ||
Accept wildcard characters: False | ||
``` | ||
### -Confirm | ||
Prompts you for confirmation before running the cmdlet. | ||
```yaml | ||
Type: System.Management.Automation.SwitchParameter | ||
Parameter Sets: (All) | ||
Aliases: cf | ||
|
||
Required: False | ||
Position: Named | ||
Default value: None | ||
Accept pipeline input: False | ||
Accept wildcard characters: False | ||
``` | ||
### -WhatIf | ||
Shows what would happen if the cmdlet runs. | ||
The cmdlet is not run. | ||
```yaml | ||
Type: System.Management.Automation.SwitchParameter | ||
Parameter Sets: (All) | ||
Aliases: wi | ||
|
||
Required: False | ||
Position: Named | ||
Default value: None | ||
Accept pipeline input: False | ||
Accept wildcard characters: False | ||
``` | ||
### CommonParameters | ||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). | ||
## INPUTS | ||
## OUTPUTS | ||
### Microsoft.Azure.PowerShell.Cmdlets.Support.Models.IFileDetails | ||
## NOTES | ||
## RELATED LINKS | ||
22 changes: 22 additions & 0 deletions
22
src/Support/Support.Autorest/examples/New-AzSupportFile.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
### Example 1: {{ Add title here }} | ||
```powershell | ||
{{ Add code here }} | ||
``` | ||
|
||
```output | ||
{{ Add output here (remove the output block if the example doesn't have an output) }} | ||
``` | ||
|
||
{{ Add description here }} | ||
|
||
### Example 2: {{ Add title here }} | ||
```powershell | ||
{{ Add code here }} | ||
``` | ||
|
||
```output | ||
{{ Add output here (remove the output block if the example doesn't have an output) }} | ||
``` | ||
|
||
{{ Add description here }} | ||
|
Oops, something went wrong.