github / github/copilot-cli

Automatically create missing directories with a tool call!

Ouverte
#1,123 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub
area:tools
Langage dominant
Shell
Étoiles
11.2k
Forks
1.9k
Merge moyen
14 h 16 min
PR mergées (30 j)
6

Description

### Describe the feature or problem you'd like to solve

When copilot-cli calls “Create” tool with a filepath which includes intermediate directories which are not existing, the tool call fails!

### Proposed solution

The “Create” tool and the other tools which create or update a file, could be smarter, and check in one go if all required directories for the given filepath are existing, and if not it creates them. I don’t understand why we have to see each time a error, then the AI has to get again asked how to handle and it starts to think again then it creates the missing directories first and finally it calls “Create” again with the content and the same filepath.

That’s so stupid, I think. Why does the tool not support the AI and just create the missing directories while it creates the file, and stops the tool from failing, because the full path wasn’t existing in forehand.

I think often that would save a lot of tokens / context window space and it would make the Agent much faster and might also reduce energy consumption in the server farm where the AI is running. It would reduce a lot of requests and save my time.

### Example prompts or workflows

I have not a specific prompt which can show this improvement / feature. But a screenshot from a session which shows the issue.

Imagehich would

### Additional context

We can make it configureable via copilot-cli config to enable or disable this feature if that would be easier for everyone.

Guide de contribution

Ouvrir le guide de contribution

Évaluation

Cette issue n'a pas encore été évaluée.

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.