aidevops 3.1.29 → 3.1.30

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/VERSION CHANGED
@@ -1 +1 @@
1
- 3.1.29
1
+ 3.1.30
package/aidevops.sh CHANGED
@@ -3,7 +3,7 @@
3
3
  # AI DevOps Framework CLI
4
4
  # Usage: aidevops <command> [options]
5
5
  #
6
- # Version: 3.1.29
6
+ # Version: 3.1.30
7
7
 
8
8
  set -euo pipefail
9
9
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aidevops",
3
- "version": "3.1.29",
3
+ "version": "3.1.30",
4
4
  "description": "AI DevOps Framework - AI-assisted development workflows, code quality, and deployment automation",
5
5
  "type": "module",
6
6
  "bin": {
package/setup.sh CHANGED
@@ -10,7 +10,7 @@ shopt -s inherit_errexit 2>/dev/null || true
10
10
  # AI Assistant Server Access Framework Setup Script
11
11
  # Helps developers set up the framework for their infrastructure
12
12
  #
13
- # Version: 3.1.29
13
+ # Version: 3.1.30
14
14
  #
15
15
  # Quick Install:
16
16
  # npm install -g aidevops && aidevops update (recommended)
@@ -1496,13 +1496,28 @@ ST_PLIST
1496
1496
  local repos_json="$HOME/.config/aidevops/repos.json"
1497
1497
  local has_profile_repo="false"
1498
1498
  if [[ -x "$pr_script" ]] && command -v gh &>/dev/null && gh auth status &>/dev/null; then
1499
- # Initialize profile repo if not already set up
1499
+ # Initialize profile repo if not already set up.
1500
+ # Verify the entry is valid: local dir exists AND README has stat markers.
1501
+ # If the repo was deleted or local clone removed, re-run init to recreate.
1502
+ local profile_needs_init="true"
1500
1503
  if [[ -f "$repos_json" ]] && command -v jq &>/dev/null; then
1501
- if jq -e '.initialized_repos[]? | select(.priority == "profile")' "$repos_json" >/dev/null 2>&1; then
1504
+ local profile_path
1505
+ profile_path=$(jq -r '
1506
+ if .initialized_repos then
1507
+ .initialized_repos[] | select(.priority == "profile") | .path
1508
+ else
1509
+ to_entries[] | select(.value.priority == "profile") | .value.path
1510
+ end
1511
+ ' "$repos_json" 2>/dev/null | head -1)
1512
+ if [[ -n "$profile_path" && "$profile_path" != "null" ]] &&
1513
+ [[ -d "$profile_path" ]] &&
1514
+ [[ -f "${profile_path}/README.md" ]] &&
1515
+ grep -q '<!-- STATS-START -->' "${profile_path}/README.md" 2>/dev/null; then
1516
+ profile_needs_init="false"
1502
1517
  has_profile_repo="true"
1503
1518
  fi
1504
1519
  fi
1505
- if [[ "$has_profile_repo" == "false" ]]; then
1520
+ if [[ "$profile_needs_init" == "true" ]]; then
1506
1521
  print_info "Setting up GitHub profile README..."
1507
1522
  if bash "$pr_script" init; then
1508
1523
  has_profile_repo="true"
@@ -1510,8 +1525,6 @@ ST_PLIST
1510
1525
  else
1511
1526
  print_warning "Profile README setup failed (non-fatal, skipping)"
1512
1527
  fi
1513
- else
1514
- has_profile_repo="true"
1515
1528
  fi
1516
1529
  elif [[ -f "$repos_json" ]] && command -v jq &>/dev/null; then
1517
1530
  # No gh CLI but check if profile repo already registered