MCPcopy Create free account
hub / github.com/AutoForgeAI/autoforge / update_project_path

Function update_project_path

registry.py:389–409  ·  view source on GitHub ↗

Update a project's path (for relocating projects). Args: name: The project name. new_path: The new absolute path. Returns: True if updated, False if project wasn't found.

(name: str, new_path: Path)

Source from the content-addressed store, hash-verified

387
388
389def update_project_path(name: str, new_path: Path) -> bool:
390 """
391 Update a project's path (for relocating projects).
392
393 Args:
394 name: The project name.
395 new_path: The new absolute path.
396
397 Returns:
398 True if updated, False if project wasn't found.
399 """
400 new_path = Path(new_path).resolve()
401
402 with _get_session() as session:
403 project = session.query(Project).filter(Project.name == name).first()
404 if not project:
405 return False
406
407 project.path = new_path.as_posix()
408
409 return True
410
411
412def get_project_concurrency(name: str) -> int:

Callers

nothing calls this directly

Calls 1

_get_sessionFunction · 0.85

Tested by

no test coverage detected