Update FAQ.md

This commit is contained in:
Markus Fleschutz 2021-04-16 16:51:04 +02:00 committed by GitHub
parent a7206cb353
commit c0d474a674
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -68,7 +68,7 @@ PowerShell scripts should follow the 11 golden rules:
4. the first line reads `#!/usr/bin/pwsh` (for Linux support)
5. provide a comment-based help with syntax, description, link, author, and license
6. check the requirements (e.g. #Requires -RunAsAdministrator, or #Requires -Version 3)
7. prefer command-line options, else ask the user
7. prefer command-line options, else ask the user for help
8. recommended is `Set-StrictMode -Version Latest` to enable additional error checking
9. for readibility use UpperCamelCase for variables and functions, lowerCamelCase for everything else
10. on error call write-error with keyword "ERROR:" (to support log parsers) and exit the error code (mostly 1)