Azure-Samples / azure-files-samples

This repository contains supporting code (PowerShell modules/scripts, ARM templates, etc.) for deploying, configuring, and using Azure Files.
https://docs.microsoft.com/azure/storage/files/storage-files-introduction
MIT License
226 stars 192 forks source link

questions about ScanUnsupportedChars.ps1(Is it able to stop the script execution in the middle; Can the script be ran multiple times using a batch file) #151

Open v-zhanyeshi opened 1 year ago

v-zhanyeshi commented 1 year ago

My customer wants to use below script to checking whether there is any unsupported characters in the file name. https://github.com/Azure-Samples/azure-files-samples/blob/master/ScanUnsupportedChars/ScanUnsupportedChars.ps1

He has below questions. I did some labs, found that seems it is not possible to stop the script execution process in the middle by either pressing Ctrl+Z, Pause Bread key, ESC key and so on. Could you give any guidance please ? Thank you.

1, How to stop ScanUnsupportedChars in the middle of the execution process and what are the concerns when stopping it? 2, Is it possible to run ScanUnsupportedChars multiple times using a batch file? 3, In the DESCRIPTION of ScanUnsupportedChars.ps1, it says ' a file name is supported but this script might say its not supported', will this cause the supported file name be renamed to a different name ? What is the impact if the supported file name is recognized as un-supportted file name ? Or are there any examples or documents about what kind of supported file name might be recognized as unsupported file names ?


Note - this script might report false positive i.e. a file name is supported but this script might say its not supported. This is by design to keep the script simple and allow customer to rename such files proactively.