requires -modules hashtable must only occur in a single line, -psedition missing
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 3/5
- Tempo estimado
- 1-2 dias
- Facilidade para iniciantes
- 45/100
- Tipo de issue
- Bug
- Clareza
- Razoavelmente clara
- Status de atividade
- Estagnada
- Stack de tecnologia
- powershell
- Domínio
- tooling
Direção de pesquisa
Start with TheBigTestFile.ps1 and locate the syntax rules or tests that handle #requires statements. Compare the multiline and single-line -Modules examples, then inspect how -psedition and abbreviated parameter names are recognized. Done means the valid single-line hashtable form and the reported parameter behavior are handled consistently.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
The hashtable option on a #requires statement must all be on one line (as all #requires statements must be), due to the fundamentals of the single line comment that it rides on, and backticks cannot be used to extend the line, nor can the quoted strings. A special syntax could be applied, but both unquoted and quoted property names are permitted, so it might not be foolproof to only syntax the known property names.
Reference TheBigTestFile.ps1:
#Requires -Modules PSWorkflow @{
ModuleName="PSScheduledJob"
ModuleVersion="1.0.0.0"
}
This is the correct syntax:
#Requires -Modules PSWorkflow, @{ModuleName="PSScheduledJob"; ModuleVersion="1.0.0.0"}
Also, the -psedition parameter is not scoped. At this time it has only known arguments, 'core' and 'desktop'.
And it also appears that these parameter names work differently and allow for shortcutting, using no more characters than required to uniquely distinguish the parameter name.
- Linguagem predominante
- PowerShell
- Estrelas
- 151
- Forks
- 55
- Métricas de merge de PRs
- Nenhum PR com merge em 30d
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.
Mais de PowerShell/EditorSyntax
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 55/100
PowerShell/EditorSyntax#224 · 2 comentários ·
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 48/100
PowerShell/EditorSyntax#222 · 2 comentários ·
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 55/100
PowerShell/EditorSyntax#221 · 2 comentários ·
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 45/100
PowerShell/EditorSyntax#220 · 2 comentários · 1 reação ·
-
Issue-Bug
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 48/100
PowerShell/EditorSyntax#219 · 2 comentários ·
Todas as issues de PowerShell/EditorSyntax
Issues semelhantes
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
idean3885/claude-ops-agent#521 ·
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
0xMiden/bridge-portal#132 ·
-
bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 84/100
newrelic-experimental/preflight#793 · 1 comentário ·
-
enhancement
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 70/100
babalae/bettergi-scripts-list#3674 ·
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 88/100
caddyserver/caddy#8046 ·