Add a fact for an unquoted glob character in the authored word
Mantenedores costumam responder em até 1 dia
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 3/5
- Tempo estimado
- 1-2 dias
- Facilidade para iniciantes
- 55/100
Direção de pesquisa
Start by locating AnalyzedArgument.MayPathnameExpand and the argument analysis code that sets it; the issue does not name files or tests. Trace how authored words and quoting are represented, then add a separate fact for unquoted authored glob characters while preserving MayPathnameExpand semantics. Verify the examples in the issue, including quoted and expansion-only cases; done means the new fact distinguishes them without changing the existing fact.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Problem
AnalyzedArgument.MayPathnameExpand (0.4.0-beta.19) is true for two different
cases:
- The authored word has an unquoted glob character (
*,?,[), for
example../netclaw/"${d}s"/*. - The authored word has an unquoted expansion whose value can contain a glob
character, for example$naftern=$(date).
A consumer cannot tell these cases apart. Netclaw needs the difference for an
output command (echo, printf):
- In case 1, the authored glob can list protected file names, so the consumer
applies its glob rule. - In case 2, the owner decision of netclaw-dev/netclaw#2349 keeps the operand
as data.
Today Netclaw cannot apply that decision when an assignment supplies the
value. n=$(date); echo $n gets one exact prompt, and an unattended run
denies it. An attempt to treat every such operand as data also made
d=key; echo ../netclaw/"${d}s"/* data, which is not safe.
Request
Add a general per-argument fact that is true only when the authored word has
an unquoted glob character. A suggested name is HasUnquotedGlobCharacter.
MayPathnameExpand keeps its meaning.
Examples
| Word | MayPathnameExpand |
New fact |
|---|---|---|
$n |
true | false |
/work/$f |
true | false |
"${d}s"/* |
true | true |
*.cs |
true | true |
"$n" |
false | false |
'*.cs' |
false | false |
A brace word stays opaque and needs no new value.
Consumer
netclaw-dev/netclaw#2349, review comment 4187346452.
- Linguagem predominante
- C#
- Estrelas
- 15
- Forks
- 0
- Merge médio
- 9h 8min
- PRs com merge (30d)
- 46
Preparar o ambiente
- Sem Dockerfile nem arquivo Docker Compose
- Sem modelo de pull request
- Ler o 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 Aaronontheweb/ShellSyntaxTree
-
Bash: an assignment in a loop body that reads the loop variable is not listed on later commandsAbertabug
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 48/100
Aaronontheweb/ShellSyntaxTree#249 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 57/100
Aaronontheweb/ShellSyntaxTree#244 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 48/100
Aaronontheweb/ShellSyntaxTree#236 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 5/5 Mais de uma semana Facilidade para iniciantes 38/100
Aaronontheweb/ShellSyntaxTree#227 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
enhancement
Dificuldade 5/5 Mais de uma semana Facilidade para iniciantes 35/100
Aaronontheweb/ShellSyntaxTree#190 ·
Mantenedores costumam responder em até 1 dia
Todas as issues de Aaronontheweb/ShellSyntaxTree
Issues semelhantes
-
sev:L
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 72/100
Systemorph/MeshWeaver#6233 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 66/100
CommunityToolkit/Aspire#2231 ·
Mantenedores costumam responder em até 1 dia
-
S: Untriaged
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 85/100
Trauma-Station/Trauma-Station#4930 ·
Mantenedores costumam responder em até 1 dia
-
agentic-workflows Needs: Triage :mag:
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 84/100
Mantenedores costumam responder em até 1 dia
-
Cyborg Reverse Hand SwappingAbertaS: Untriaged
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 76/100
new-frontiers-14/frontier-station-14#4900 ·
Mantenedores costumam responder em até 2 dias