Skip to content

Commit 7fe09ce

Browse files
Merge pull request #222940 from khdownie/kendownie010423
minor edits to CLI
2 parents 319d954 + 8c1bc92 commit 7fe09ce

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

articles/storage/files/storage-how-to-use-files-portal.md

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -204,10 +204,12 @@ New-AzStorageDirectory `
204204

205205
To create a new directory named **myDirectory** at the root of your Azure file share, use the [`az storage directory create`](/cli/azure/storage/directory) command:
206206

207+
> [!NOTE]
208+
> If you don't provide credentials with your commands, Azure CLI will query for your storage account key. You can also provide your storage account key with the command by using a variable such as `--account-key $storageAccountKey` or in plain text such as `--account-key "your-storage-account-key-here"`.
209+
207210
```azurecli-interactive
208211
az storage directory create \
209212
--account-name $storageAccountName \
210-
--account-key $storageAccountKey \
211213
--share-name $shareName \
212214
--name "myDirectory" \
213215
--output none
@@ -273,7 +275,6 @@ date > SampleUpload.txt
273275
274276
az storage file upload \
275277
--account-name $storageAccountName \
276-
--account-key $storageAccountKey \
277278
--share-name $shareName \
278279
--source "SampleUpload.txt" \
279280
--path "myDirectory/SampleUpload.txt"
@@ -286,7 +287,6 @@ After you upload the file, you can use the [`az storage file list`](/cli/azure/s
286287
```azurecli-interactive
287288
az storage file list \
288289
--account-name $storageAccountName \
289-
--account-key $storageAccountKey \
290290
--share-name $shareName \
291291
--path "myDirectory" \
292292
--output table
@@ -335,10 +335,9 @@ rm -f SampleDownload.txt
335335
336336
az storage file download \
337337
--account-name $storageAccountName \
338-
--account-key $storageAccountKey \
339338
--share-name $shareName \
340339
--path "myDirectory/SampleUpload.txt" \
341-
--dest "SampleDownload.txt" \
340+
--dest "./SampleDownload.txt" \
342341
--output none
343342
```
344343

0 commit comments

Comments
 (0)