PowerShell / PowerShell/PSScriptAnalyzer
Make custom rule name consistent
Ninguém assumiu esta issue ainda.
- Linguagem predominante
- C#
- Estrelas
- 2.2k
- Forks
- 415
- Merge médio
- 13h 1min
- PRs com merge (30d)
- 2
Descrição
Apologies if I am repeating something or if this has been discussed already. This is mostly an re-iteration of https://github.com/PowerShell/PSScriptAnalyzer/issues/1140#issuecomment-488251888
As of now, custom rule names are inconsistent across various places.
- At first, there are no indication about function name in the ScriptRuleDocumention.md . But PSSA is completely depends on
$MyInvocation.InvocationNamefor rule/violation name - I can not really have a customized rule name, it should be the name of the PS function. That gives me a weird naming of rules like
Measure-Something. On the other I can ship the violation with whatever name I like which has no value and can break things. - While suppressing a custom rule, I will have to provide
<ModuleName>\<RuleName>. That would end up something like,FooBar\Measure-Something- I really do not like this convention as I do not want the developer to be aware of the module name or the function name.
- It gets worst further, While filtering a rule, I can not follow the same convention, it has to be the name whatever the function name.
Invoke-ScriptAnalyzer -IncludeRule Measure-Something -ExcludeRule Measure-SomethingElse
Guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Direção de pesquisa
Comece com ScriptRuleDocumentation.md e com o comportamento de Invoke-ScriptAnalyzer IncludeRule/ExcludeRule e de supressão descrito aqui; revise a discussão da issue vinculada para obter o contexto anterior. Considera-se concluído quando a convenção de nomenclatura para regras personalizadas estiver decidida e for aplicada de forma consistente à documentação, aos nomes das violações, à supressão e à filtragem.
Escrita pelo modelo de indexação a partir do texto da issue.
Avaliação
- Stack de tecnologia
- powershell
- Domínio
- tooling
- Tipo de issue
- Funcionalidade
- Dificuldade
- 5/5
- Tempo estimado
- Mais de uma semana
- Status de atividade
- Estagnada
- Clareza
- Precisa de esclarecimento
- Facilidade para iniciantes
- 30/100