ai-git-tools 2.0.31 → 2.0.32

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ai-git-tools",
3
- "version": "2.0.31",
3
+ "version": "2.0.32",
4
4
  "description": "AI-powered Git automation tools for commit messages and PR generation",
5
5
  "main": "src/index.js",
6
6
  "type": "module",
@@ -117,9 +117,13 @@ export class GitHubAPI {
117
117
  // 先檢查認證狀態
118
118
  const authStatus = this.checkAuth();
119
119
  if (!authStatus.authenticated) {
120
- log.warning('GitHub CLI 未認證');
121
- log.info('請執行: gh auth login\n');
122
- return { teams: {}, members: [] };
120
+ log.error('\n❌ GitHub CLI 未認證\n');
121
+ console.log('請先執行認證:');
122
+ console.log(` ${colors.green}gh auth login${colors.reset}\n`);
123
+ console.log('選擇認證範圍時,請確保包含:');
124
+ console.log(' - repo (必需)');
125
+ console.log(' - read:org (如需使用 reviewer 功能)\n');
126
+ throw new Error('GitHub CLI 未認證,無法創建 PR');
123
127
  }
124
128
 
125
129
  log.step(`正在從 GitHub 抓取 ${orgName} 的團隊資訊...`);