{% extends "projects_shell.html" %} {% from "_macros.html" import icon, ref, due_buckets, goal_card %} {% from "_project_macros.html" import status_labels, close_menu %} {% set lane_labels = {"problems": "Problem", "your_move": "Your move", "asks": "Ask pending", "in_transit": "In transit", "review": "Review"} %} {% block tab %}

Goals

{% if not outcomes %}

Concrete results you're working toward, each with a checklist of steps owned by you, an agent or someone else. A project can have several, one after another.

{% endif %} {% if outcomes %}
{% for o in outcomes %}{{ goal_card(o, "/projects/" ~ p.id) }}{% endfor %}
{% endif %} {% if not p.archived %}
{{ icon("plus") }}Start a goal
{% endif %}
{% set waiting = namespace(n=0) %} {% for lane, item in items %}{% if lane in ("problems", "your_move", "asks") %}{% set waiting.n = waiting.n + 1 %}{% endif %}{% endfor %}

{{ icon("zap") }}{% if waiting.n %}{{ waiting.n }} waiting on you{% else %}Nothing here is waiting on you{% endif %}. Open in Now

{{ due_buckets(work, "/projects/" ~ p.id ~ "/work") }}
{% set repos = ready_to_merge | selectattr("branches") | list %} {% if repos or merged or merge_error or (ready_to_merge | selectattr("blocked") | list) %}

Ready to merge

Branches with work their main branch doesn't have yet
{% include "_merge_result.html" %} {% for r in repos %} {% if ready_to_merge | length > 1 %}

{{ r.folder.label or r.folder.name }} {{ r.folder.local_path | home }}

{% endif %} {% if r.blocked %}

{{ icon("alert") }}{{ r.blocked }}

{% endif %}
    {% for b in r.branches %} {% if loop.index == 9 %}
{{ r.branches | length - 8 }} more branch{{ "es" if r.branches | length - 8 != 1 }}
    {% endif %}
  • {{ b.branch }} {% if b.item %}{{ ref(b.item.id) }}{{ b.item.title }}{% endif %}
    {% if b.unrelated %}No history in common with {{ r.default_branch }}{% else %}{{ b.ahead }} commit{{ "s" if b.ahead != 1 }} to merge{% if b.behind %}, {{ b.behind }} behind{% endif %}{% endif %} · {{ b.subject }} · {{ b.at | ago }}{% if b.worktree %} · in {{ b.worktree | home }}{% endif %} {%- if b.subagent %} · by subagent “{{ b.subagent }}”{% if b.session %} of {{ b.session.name }}{% endif %} {%- elif b.session %} · by {{ b.session.name }}{% endif %}
    {% if b.conflicts %}
    {{ icon("alert") }}Likely to conflict in {{ b.conflicts | join(", ") }}
    {% endif %} {% if b.unrelated %}No history in common with {{ r.default_branch }}, so no Merge. {% else %}{{ b.command | home }}{% endif %}
    {% if not b.unrelated %}
    {% endif %}
  • {% endfor %}
{% if r.branches | length > 8 %}
{% endif %} {% endfor %}
{% endif %} {% if rule_suggestion %}

{{ icon("bulb") }}You accepted the agent's suggestion on {{ rule_suggestion.accepted }} of {{ rule_suggestion.answered }} decisions here lately. Make it a standing rule

{% endif %}

Recently

{%- set n = changes.commits | length -%} {%- if n or changes.prs %}{{ n }} commit{{ "s" if n != 1 }} {%- if changes.merged %} · {{ changes.merged }} PR{{ "s" if changes.merged != 1 }} merged{% endif %} {%- if changes.opened %} · {{ changes.opened }} PR{{ "s" if changes.opened != 1 }} open{% endif %} in 7 days {%- elif repositories %}No commits in the last 7 days{% endif %} {%- if changes.new %} · {{ changes.new }} new since you last looked{% endif %} All activity {{ icon("arrow-right") }}
{% if recent %}
    {% for r in recent %}
  • {%- if r.kind == "pr" %}{{ "Merged" if r.state == "MERGED" else ("Draft" if r.isDraft else "Open") }} #{{ r.number }} {{ r.title }} {%- elif r.kind == "commit" %}{{ r.short }} {{ r.subject }} {%- if changes.several_folders %} {{ r.folder }}{% endif %} {%- elif r.decision_id %}{{ r.summary }} {%- else %}{{ r.summary }}{% endif %} {%- if r.repeat and r.repeat > 1 %} ×{{ r.repeat }}{% endif %}
  • {% endfor %}
{% else %}

Nothing recorded yet.

{% endif %}
{% endblock %}