mirror of
https://github.com/FoundationAgents/MetaGPT.git
synced 2026-06-26 15:49:42 +02:00
Merge branch 'main' into feature/fork_meta_role
This commit is contained in:
commit
36386ce143
4 changed files with 13 additions and 2 deletions
|
|
@ -93,6 +93,7 @@ class Engineer(Role):
|
|||
|
||||
def write_file(self, filename: str, code: str):
|
||||
workspace = self.get_workspace()
|
||||
filename = filename.replace('"', '').replace('\n', '')
|
||||
file = workspace / filename
|
||||
file.parent.mkdir(parents=True, exist_ok=True)
|
||||
file.write_text(code)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue