Skip to content

[109c] start resolution chain (project → user → prompt-init) + --scope #112

@fedorovvvv

Description

@fedorovvvv

Sub-issue of #109.

Goal

npx @forgeplan/web start should Just Work — find a scaffold automatically, prompt to init if none exists.

Scope

  • Resolution order: <cwd>/.forgeplan-web/~/.forgeplan-web/ → prompt user to run init.
  • --scope user|project overrides resolution (force the chosen scope, fail loudly if absent).
  • Honor FORGEPLAN_CWD env (current behavior preserved).
  • New helper: resolveScaffold({ cwd, scope }){ path, scope, configPath } | null.

Forgeplan

  • PRD-026 + RFC-021

Acceptance

  • cd /any/dir && npx @forgeplan/web start starts user-scope server when project-scope absent.
  • --scope project in a dir without .forgeplan-web/ errors clearly without falling back to user.
  • No .forgeplan-web/ anywhere → prompt offers init --scope user|project interactively.
  • Existing project-scope users see no behavior change.

Depends on

  • 109b (scope flag, user-scope path resolver)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions