claude-mpm 4.7.8__py3-none-any.whl → 4.7.9__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
claude_mpm/VERSION CHANGED
@@ -1 +1 @@
1
- 4.7.8
1
+ 4.7.9
@@ -12,7 +12,7 @@ import contextlib
12
12
  import subprocess
13
13
  import sys
14
14
  from pathlib import Path
15
- from typing import Dict, List, Optional
15
+ from typing import Any, Dict, List, Optional
16
16
 
17
17
  import click
18
18
  from rich.console import Console
@@ -63,6 +63,7 @@ class MPMInitCommand:
63
63
  skip_archive: bool = False,
64
64
  dry_run: bool = False,
65
65
  quick_update: bool = False,
66
+ catchup: bool = False,
66
67
  non_interactive: bool = False,
67
68
  days: int = 30,
68
69
  export: Optional[str] = None,
@@ -84,6 +85,7 @@ class MPMInitCommand:
84
85
  skip_archive: Skip archiving existing files
85
86
  dry_run: Show what would be done without making changes
86
87
  quick_update: Perform lightweight update based on recent git activity
88
+ catchup: Show recent commit history from all branches for PM context
87
89
  non_interactive: Non-interactive mode - display report only without prompting
88
90
  days: Number of days for git history analysis (7, 14, 30, 60, or 90)
89
91
  export: Export report to file (path or "auto" for default location)
@@ -99,6 +101,11 @@ class MPMInitCommand:
99
101
  if review_only:
100
102
  return self._run_review_mode()
101
103
 
104
+ if catchup:
105
+ data = self._catchup()
106
+ self._display_catchup(data)
107
+ return {"status": "success", "mode": "catchup", "catchup_data": data}
108
+
102
109
  if quick_update:
103
110
  return self._run_quick_update_mode(
104
111
  days=days,
@@ -679,6 +686,142 @@ The final CLAUDE.md should be a comprehensive, well-organized guide that any AI
679
686
  console.print("\n[yellow]Quick update cancelled[/yellow]")
680
687
  return {"status": "cancelled", "message": "Quick update cancelled"}
681
688
 
689
+ def _catchup(self) -> Dict[str, Any]:
690
+ """Get recent commit history for PM context.
691
+
692
+ Returns:
693
+ Dict containing commit history and contributor stats
694
+ """
695
+ from collections import Counter
696
+ from datetime import datetime
697
+ from subprocess import run
698
+
699
+ try:
700
+ # Get last 25 commits from all branches with author info
701
+ result = run(
702
+ ["git", "log", "--all", "--format=%h|%an|%ai|%s", "-25"],
703
+ capture_output=True,
704
+ text=True,
705
+ check=True,
706
+ cwd=str(self.project_path),
707
+ )
708
+
709
+ commits = []
710
+ authors = []
711
+
712
+ for line in result.stdout.strip().split("\n"):
713
+ if not line:
714
+ continue
715
+
716
+ parts = line.split("|", 3)
717
+ if len(parts) == 4:
718
+ hash_val, author, date_str, message = parts
719
+
720
+ # Parse date
721
+ try:
722
+ dt = datetime.fromisoformat(date_str.replace(" ", "T", 1))
723
+ date_display = dt.strftime("%Y-%m-%d %H:%M")
724
+ except Exception:
725
+ date_display = date_str[:16]
726
+
727
+ commits.append(
728
+ {
729
+ "hash": hash_val,
730
+ "author": author,
731
+ "date": date_display,
732
+ "message": message,
733
+ }
734
+ )
735
+ authors.append(author)
736
+
737
+ # Calculate contributor stats
738
+ author_counts = Counter(authors)
739
+
740
+ return {
741
+ "commits": commits,
742
+ "total_commits": len(commits),
743
+ "contributors": dict(author_counts),
744
+ "contributor_count": len(author_counts),
745
+ }
746
+
747
+ except Exception as e:
748
+ console.print(f"[yellow]Could not retrieve commit history: {e}[/yellow]")
749
+ return {
750
+ "commits": [],
751
+ "total_commits": 0,
752
+ "contributors": {},
753
+ "contributor_count": 0,
754
+ "error": str(e),
755
+ }
756
+
757
+ def _display_catchup(self, data: Dict[str, Any]) -> None:
758
+ """Display catchup information to console.
759
+
760
+ Args:
761
+ data: Commit history data from _catchup()
762
+ """
763
+ from rich.panel import Panel
764
+ from rich.table import Table
765
+
766
+ if data.get("error"):
767
+ console.print(
768
+ Panel(
769
+ "[yellow]Not a git repository or no commits found[/yellow]",
770
+ title="⚠️ Catchup Status",
771
+ border_style="yellow",
772
+ )
773
+ )
774
+ return
775
+
776
+ # Display contributor summary
777
+ if data["contributors"]:
778
+ console.print("\n[bold cyan]👥 Active Contributors[/bold cyan]")
779
+ for author, count in sorted(
780
+ data["contributors"].items(), key=lambda x: x[1], reverse=True
781
+ ):
782
+ console.print(
783
+ f" • [green]{author}[/green]: {count} commit{'s' if count != 1 else ''}"
784
+ )
785
+
786
+ # Display commit history table
787
+ if data["commits"]:
788
+ console.print(
789
+ f"\n[bold cyan]📝 Last {data['total_commits']} Commits[/bold cyan]"
790
+ )
791
+
792
+ table = Table(
793
+ show_header=True, header_style="bold magenta", border_style="dim"
794
+ )
795
+ table.add_column("#", style="dim", width=3)
796
+ table.add_column("Hash", style="yellow", width=8)
797
+ table.add_column("Author", style="green", width=20)
798
+ table.add_column("Date", style="cyan", width=16)
799
+ table.add_column("Message", style="white")
800
+
801
+ for idx, commit in enumerate(data["commits"], 1):
802
+ # Truncate message if too long
803
+ msg = commit["message"]
804
+ if len(msg) > 80:
805
+ msg = msg[:77] + "..."
806
+
807
+ # Truncate author if too long
808
+ author = commit["author"]
809
+ if len(author) > 18:
810
+ author = author[:18] + "..."
811
+
812
+ table.add_row(str(idx), commit["hash"], author, commit["date"], msg)
813
+
814
+ console.print(table)
815
+
816
+ # Display PM recommendations
817
+ console.print("\n[bold cyan]💡 PM Recommendations[/bold cyan]")
818
+ console.print(
819
+ f" • Total activity: {data['total_commits']} commits from {data['contributor_count']} contributor{'s' if data['contributor_count'] != 1 else ''}"
820
+ )
821
+ console.print(" • Review commit messages for recent project context")
822
+ console.print(" • Identify development patterns and focus areas")
823
+ console.print(" • Use this context to inform current work priorities\n")
824
+
682
825
  def _generate_activity_report(
683
826
  self, git_analysis: Dict, doc_analysis: Dict, days: int = 30
684
827
  ) -> Dict:
@@ -1463,6 +1606,11 @@ preserving valuable project-specific information while refreshing standard secti
1463
1606
  is_flag=True,
1464
1607
  help="Perform lightweight update based on recent git activity (default: 30 days)",
1465
1608
  )
1609
+ @click.option(
1610
+ "--catchup",
1611
+ is_flag=True,
1612
+ help="Show recent commit history from all branches for PM context",
1613
+ )
1466
1614
  @click.option(
1467
1615
  "--non-interactive",
1468
1616
  is_flag=True,
@@ -1499,6 +1647,7 @@ def mpm_init(
1499
1647
  verbose,
1500
1648
  ast_analysis,
1501
1649
  quick_update,
1650
+ catchup,
1502
1651
  non_interactive,
1503
1652
  days,
1504
1653
  export,
@@ -1544,6 +1693,7 @@ def mpm_init(
1544
1693
  preserve_custom=preserve_custom,
1545
1694
  skip_archive=skip_archive,
1546
1695
  quick_update=quick_update,
1696
+ catchup=catchup,
1547
1697
  non_interactive=non_interactive,
1548
1698
  days=days,
1549
1699
  export=export,
@@ -91,6 +91,11 @@ def add_mpm_init_subparser(subparsers: Any) -> None:
91
91
  action="store_true",
92
92
  help="Perform lightweight update based on recent git activity (default: 30 days)",
93
93
  )
94
+ init_group.add_argument(
95
+ "--catchup",
96
+ action="store_true",
97
+ help="Show recent commit history from all branches for PM context",
98
+ )
94
99
  init_group.add_argument(
95
100
  "--non-interactive",
96
101
  action="store_true",
@@ -146,6 +146,23 @@ Fast update based on recent 30-day git activity. Generates activity report and u
146
146
 
147
147
  **Note**: Typing `/mpm-init update` executes `claude-mpm mpm-init --quick-update` automatically.
148
148
 
149
+ ### Catchup Mode
150
+
151
+ Show recent commit history to provide PM with project context:
152
+
153
+ ```bash
154
+ /mpm-init catchup
155
+ ```
156
+
157
+ This displays:
158
+ - Last 25 commits from all branches
159
+ - Author attribution (WHO did WHAT)
160
+ - Temporal context (WHEN)
161
+ - Contributor activity summary
162
+ - PM recommendations based on commit patterns
163
+
164
+ Useful for understanding recent development activity and getting PM up to speed on project changes.
165
+
149
166
  ### Review Project State
150
167
  ```bash
151
168
  /mpm-init --review
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: claude-mpm
3
- Version: 4.7.8
3
+ Version: 4.7.9
4
4
  Summary: Claude Multi-Agent Project Manager - Orchestrate Claude with agent delegation and ticket tracking
5
5
  Author-email: Bob Matsuoka <bob@matsuoka.com>
6
6
  Maintainer: Claude MPM Team
@@ -1,5 +1,5 @@
1
1
  claude_mpm/BUILD_NUMBER,sha256=9JfxhnDtr-8l3kCP2U5TVXSErptHoga8m7XA8zqgGOc,4
2
- claude_mpm/VERSION,sha256=XWuLX-eNJrJGfyBd1GUrzseop7w6skHL0X8KHS__eFE,6
2
+ claude_mpm/VERSION,sha256=7-IAGCtmvIwdixVQJDoq-zKnNOnvOHQb0ZEINbbBPJ4,6
3
3
  claude_mpm/__init__.py,sha256=UCw6j9e_tZQ3kJtTqmdfNv7MHyw9nD1jkj80WurwM2g,2064
4
4
  claude_mpm/__main__.py,sha256=Ro5UBWBoQaSAIoSqWAr7zkbLyvi4sSy28WShqAhKJG0,723
5
5
  claude_mpm/constants.py,sha256=cChN3myrAcF3jC-6DvHnBFTEnwlDk-TAsIXPvUZr_yw,5953
@@ -96,7 +96,7 @@ claude_mpm/cli/commands/mcp_setup_external.py,sha256=hfBHkaioNa0JRDhahNEc8agyrUw
96
96
  claude_mpm/cli/commands/mcp_tool_commands.py,sha256=q17GzlFT3JiLTrDqwPO2tz1-fKmPO5QU449syTnKTz4,1283
97
97
  claude_mpm/cli/commands/memory.py,sha256=O4T5HGL-Ob_QPt2dZHQvoOrVohnaDKrBjyngq1Mcv1w,26185
98
98
  claude_mpm/cli/commands/monitor.py,sha256=Fjb68hf3dEwTFek2LV8Nh6iU0qEkY7qYlOn32IwNaNg,9566
99
- claude_mpm/cli/commands/mpm_init.py,sha256=H7op69CaE7VPOViTuEiCTeANe708ZAcJpkpgbfG2baM,60311
99
+ claude_mpm/cli/commands/mpm_init.py,sha256=njopKyRBzBT_FL-3LrqishRSeKtIESehzWinhUqmRpM,65724
100
100
  claude_mpm/cli/commands/mpm_init_handler.py,sha256=b1CSwZYJ89wMorKzPOKS-RVxOKR2kT9yv9KQLvKkd2U,3532
101
101
  claude_mpm/cli/commands/run.py,sha256=PB2H55piOPTy4yo4OBgbUCjMlcz9K79wbwpxQVc9m5Q,48225
102
102
  claude_mpm/cli/commands/search.py,sha256=_0qbUnop8v758MHsB0fAop8FVxwygD59tec_-iN7pLE,9806
@@ -118,7 +118,7 @@ claude_mpm/cli/parsers/debug_parser.py,sha256=F7MZdmiXiPfiIPMv21ZUqB2cMT8Ho1LDmp
118
118
  claude_mpm/cli/parsers/mcp_parser.py,sha256=2j6ULhdu55Z2k_-Gu2QxIsFoTQFbDCEMSGePXSuPoQQ,6532
119
119
  claude_mpm/cli/parsers/memory_parser.py,sha256=ZwCDxJEgp-w03L-1tZsWTgisiwamP42s424bA5bvDJc,4760
120
120
  claude_mpm/cli/parsers/monitor_parser.py,sha256=PeoznSi_5Bw6THK_Espl8M20o6dKvvBSmFzAbovkaFQ,4920
121
- claude_mpm/cli/parsers/mpm_init_parser.py,sha256=jMV67caBeC-LV-oOuAGJXvFbiBJQ4nGcl6ggfX0_7jI,7662
121
+ claude_mpm/cli/parsers/mpm_init_parser.py,sha256=iTMd3RjnHzz89Q0O5Lr0MYI_vOUuXQOHHI6D-Zy8PUE,7823
122
122
  claude_mpm/cli/parsers/run_parser.py,sha256=cs34qNonFZG8uYxTYEt0rXi2LcPz3pw8D8hxiywih6w,4927
123
123
  claude_mpm/cli/parsers/search_parser.py,sha256=L8-65kndg-zutSKpzj-eCvTNkeySCZ-WlSHdhk7pEak,6916
124
124
  claude_mpm/cli/parsers/tickets_parser.py,sha256=FYl-VNH7PrZzfZUCcjnf6F7g6JXnL8YDxwrmR5svIcg,6966
@@ -136,7 +136,7 @@ claude_mpm/commands/mpm-agents.md,sha256=JnYPJ-eWvIEEtiCB6iPu182P2xDBRvU3ArVXQ7h
136
136
  claude_mpm/commands/mpm-config.md,sha256=79Eb-srRpEVV3HCHDHZc8SKec6_LVP6HbXDEVkZKLgw,2929
137
137
  claude_mpm/commands/mpm-doctor.md,sha256=ut5LhFKVRw-2ecjMSPsnaTiRuFXa6Q9t-Wgl3CCnQvk,590
138
138
  claude_mpm/commands/mpm-help.md,sha256=zfhpE0Fd-wW5zWmYYAMRMT-xYK8saqbw-HXRD7csJHI,2850
139
- claude_mpm/commands/mpm-init.md,sha256=hVVr71X0w67O08B_x9wP2FRijtkLUVIHWDi-0FSBRPA,10291
139
+ claude_mpm/commands/mpm-init.md,sha256=5Jqb99qqJ_hQ_41lGmyTyDUhm7V7wQiLCYvksd3tZEo,10696
140
140
  claude_mpm/commands/mpm-monitor.md,sha256=onTHf9Yac1KkdZdENtY2Q5jyw0A-vZLYgoKkPCtZLUY,12193
141
141
  claude_mpm/commands/mpm-organize.md,sha256=T-ysjhwgfW9irjUj02vuY_1jeMdabO_zxcShyjmqsiM,10153
142
142
  claude_mpm/commands/mpm-status.md,sha256=oaM4ybL4ffp55nkT9F0mp_5H4tF-wX9mbqK-LEKEqUU,1919
@@ -786,9 +786,9 @@ claude_mpm/utils/subprocess_utils.py,sha256=D0izRT8anjiUb_JG72zlJR_JAw1cDkb7kalN
786
786
  claude_mpm/validation/__init__.py,sha256=YZhwE3mhit-lslvRLuwfX82xJ_k4haZeKmh4IWaVwtk,156
787
787
  claude_mpm/validation/agent_validator.py,sha256=GprtAvu80VyMXcKGsK_VhYiXWA6BjKHv7O6HKx0AB9w,20917
788
788
  claude_mpm/validation/frontmatter_validator.py,sha256=YpJlYNNYcV8u6hIOi3_jaRsDnzhbcQpjCBE6eyBKaFY,7076
789
- claude_mpm-4.7.8.dist-info/licenses/LICENSE,sha256=lpaivOlPuBZW1ds05uQLJJswy8Rp_HMNieJEbFlqvLk,1072
790
- claude_mpm-4.7.8.dist-info/METADATA,sha256=0zNQ_GqGZeqiE8cxEiJK7LQNZ6gfeuJyvsVrunOlrEE,17517
791
- claude_mpm-4.7.8.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
792
- claude_mpm-4.7.8.dist-info/entry_points.txt,sha256=Vlw3GNi-OtTpKSrez04iNrPmxNxYDpIWxmJCxiZ5Tx8,526
793
- claude_mpm-4.7.8.dist-info/top_level.txt,sha256=1nUg3FEaBySgm8t-s54jK5zoPnu3_eY6EP6IOlekyHA,11
794
- claude_mpm-4.7.8.dist-info/RECORD,,
789
+ claude_mpm-4.7.9.dist-info/licenses/LICENSE,sha256=lpaivOlPuBZW1ds05uQLJJswy8Rp_HMNieJEbFlqvLk,1072
790
+ claude_mpm-4.7.9.dist-info/METADATA,sha256=CKRPRgDYQjMEhisRDRh4swunx7DxHsVA022PufJ0t7Q,17517
791
+ claude_mpm-4.7.9.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
792
+ claude_mpm-4.7.9.dist-info/entry_points.txt,sha256=Vlw3GNi-OtTpKSrez04iNrPmxNxYDpIWxmJCxiZ5Tx8,526
793
+ claude_mpm-4.7.9.dist-info/top_level.txt,sha256=1nUg3FEaBySgm8t-s54jK5zoPnu3_eY6EP6IOlekyHA,11
794
+ claude_mpm-4.7.9.dist-info/RECORD,,