Skip to content

Commit d22f45f

Browse files
authored
Fix typos in examples for New-AzStorageContext
1 parent bb75a87 commit d22f45f

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

src/Storage/Storage.Management/help/New-AzStorageContext.md

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
---
1+
---
22
external help file: Microsoft.Azure.PowerShell.Cmdlets.Storage.dll-Help.xml
33
Module Name: Az.Storage
44
ms.assetid: 383402B2-6B7C-41AB-AFF9-36C86156B0A9
@@ -78,45 +78,45 @@ The **New-AzStorageContext** cmdlet creates an Azure Storage context.
7878

7979
### Example 1: Create a context by specifying a storage account name and key
8080
```
81-
C:\PS>New-AzStorageContext -StorageAccountName "ContosoGeneral" -StorageAccountKey "< Storage Key for ContosoGeneral ends with == >"
81+
PS C:\>New-AzStorageContext -StorageAccountName "ContosoGeneral" -StorageAccountKey "< Storage Key for ContosoGeneral ends with == >"
8282
```
8383

8484
This command creates a context for the account named ContosoGeneral that uses the specified key.
8585

8686
### Example 2: Create a context by specifying a connection string
8787
```
88-
C:\PS>New-AzStorageContext -ConnectionString "DefaultEndpointsProtocol=https;AccountName=ContosoGeneral;AccountKey=< Storage Key for ContosoGeneral ends with == >;"
88+
PS C:\>New-AzStorageContext -ConnectionString "DefaultEndpointsProtocol=https;AccountName=ContosoGeneral;AccountKey=< Storage Key for ContosoGeneral ends with == >;"
8989
```
9090

9191
This command creates a context based on the specified connection string for the account ContosoGeneral.
9292

9393
### Example 3: Create a context for an anonymous storage account
9494
```
95-
C:\PS>New-AzStorageContext -StorageAccountName "ContosoGeneral" -Anonymous -Protocol "http"
95+
PS C:\>New-AzStorageContext -StorageAccountName "ContosoGeneral" -Anonymous -Protocol "http"
9696
```
9797

9898
This command creates a context for anonymous use for the account named ContosoGeneral.
9999
The command specifies HTTP as a connection protocol.
100100

101101
### Example 4: Create a context by using the local development storage account
102102
```
103-
C:\PS>New-AzStorageContext -Local
103+
PS C:\>New-AzStorageContext -Local
104104
```
105105

106106
This command creates a context by using the local development storage account.
107107
The command specifies the *Local* parameter.
108108

109109
### Example 5: Get the container for the local developer storage account
110110
```
111-
C:\PS>New-AzStorageContext -Local | Get-AzStorageContainer
111+
PS C:\>New-AzStorageContext -Local | Get-AzStorageContainer
112112
```
113113

114114
This command creates a context by using the local development storage account, and then passes the new context to the **Get-AzStorageContainer** cmdlet by using the pipeline operator.
115115
The command gets the Azure Storage container for the local developer storage account.
116116

117117
### Example 6: Get multiple containers
118118
```
119-
C:\PS>$Context01 = New-AzStorageContext -Local
119+
PS C:\>$Context01 = New-AzStorageContext -Local
120120
PS C:\> $Context02 = New-AzStorageContext -StorageAccountName "ContosoGeneral" -StorageAccountKey "< Storage Key for ContosoGeneral ends with == >"
121121
PS C:\> ($Context01, $Context02) | Get-AzStorageContainer
122122
```
@@ -127,23 +127,23 @@ The final command gets the containers for the contexts stored in $Context01 and
127127

128128
### Example 7: Create a context with an endpoint
129129
```
130-
C:\PS>New-AzStorageContext -StorageAccountName "ContosoGeneral" -StorageAccountKey "< Storage Key for ContosoGeneral ends with == >" -Endpoint "contosoaccount.core.windows.net"
130+
PS C:\>New-AzStorageContext -StorageAccountName "ContosoGeneral" -StorageAccountKey "< Storage Key for ContosoGeneral ends with == >" -Endpoint "contosoaccount.core.windows.net"
131131
```
132132

133133
This command creates an Azure Storage context that has the specified storage endpoint.
134134
The command creates the context for the account named ContosoGeneral that uses the specified key.
135135

136136
### Example 8: Create a context with a specified environment
137137
```
138-
C:\PS>New-AzStorageContext -StorageAccountName "ContosoGeneral" -StorageAccountKey "< Storage Key for ContosoGeneral ends with == >" -Environment "AzureChinaCloud"
138+
PS C:\>New-AzStorageContext -StorageAccountName "ContosoGeneral" -StorageAccountKey "< Storage Key for ContosoGeneral ends with == >" -Environment "AzureChinaCloud"
139139
```
140140

141141
This command creates an Azure storage context that has the specified Azure environment.
142142
The command creates the context for the account named ContosoGeneral that uses the specified key.
143143

144144
### Example 9: Create a context by using an SAS token
145145
```
146-
C:\PS>$SasToken = New-AzStorageContainerSASToken -Name "ContosoMain" -Permission "rad"
146+
PS C:\>$SasToken = New-AzStorageContainerSASToken -Name "ContosoMain" -Permission "rad"
147147
PS C:\> $Context = New-AzStorageContext -StorageAccountName "ContosoGeneral" -SasToken $SasToken
148148
PS C:\> $Context | Get-AzStorageBlob -Container "ContosoMain"
149149
```
@@ -155,8 +155,8 @@ The final command lists all the blobs associated with the container named Contos
155155

156156
### Example 10: Create a context by using the OAuth Authentication
157157
```
158-
C:\PS>Connect-AzAccount
159-
C:\PS> $Context = New-AzStorageContext -StorageAccountName "myaccountname" -UseConnectedAccount
158+
PS C:\>Connect-AzAccount
159+
PS C:\> $Context = New-AzStorageContext -StorageAccountName "myaccountname" -UseConnectedAccount
160160
```
161161

162162
This command creates a context by using the OAuth Authentication.

0 commit comments

Comments
 (0)