PowerShell / PowerShell/PSScriptAnalyzer

Definitions for Information, Warning, and Error Severities

未關閉
#467 0 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

還沒有人認領這個 Issue。

Area - Documentation Issue - Enhancement
主要語言
C#
星號
2.2k
分支
415
平均合併
13 小時 1 分鐘
30 天內合併 PR
2

描述

In the code comments for the RuleSeverity enum, a warning does not follow PowerShell's "recommended" guidelines and Errors do not conform to PowerShell's "required" guidelines. Information rules are "recommended by PowerShell best practice".

I just posted #466 and now that I am thinking about it, I am not sure what the specific criteria is that would differentiate Warnings from Errors. For my team, at my company, we cannot have any hard coded passwords in a script, so this would definitely be an Error. However, that might not be the case for everyone everywhere.

The definitions of Warning and Error severity should be clearly defined in the documentation. I have some ideas and opinions here, as I am sure everyone in the PS community does. Would it make sense to use https://github.com/PoshCode/PowerShellPracticeAndStyle as a starting point for best practices and guidelines?

I am also wondering if it would make sense to have the ability to override severity levels for built in rules.

貢獻指南

開啟貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

研究方向

從 RuleSeverity 列舉註解著手,並將其目前的措辭與 issue 中連結的 PowerShellPracticeAndStyle 指南進行比較。定義並記錄區分 Information、Warning 和 Error 嚴重性級別的標準,並明確內建嚴重性覆寫是否在範圍內。

由索引模型根據 Issue 內容生成。

評估

技術堆疊
powershell
領域
documentation
Issue 類型
文件
難度
5/5
預估耗時
一週以上
活躍度
停滯
描述清晰度
需要釐清
新手友好度
25/100

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。