aidevops 2.136.0 → 2.137.0
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 +1 -1
- package/aidevops.sh +65 -6
- package/package.json +1 -1
- package/setup.sh +3 -1
package/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
2.
|
|
1
|
+
2.137.0
|
package/aidevops.sh
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
# AI DevOps Framework CLI
|
|
4
4
|
# Usage: aidevops <command> [options]
|
|
5
5
|
#
|
|
6
|
-
# Version: 2.
|
|
6
|
+
# Version: 2.137.0
|
|
7
7
|
|
|
8
8
|
set -euo pipefail
|
|
9
9
|
|
|
@@ -88,10 +88,44 @@ init_repos_file() {
|
|
|
88
88
|
rm -f "$temp_file"
|
|
89
89
|
fi
|
|
90
90
|
fi
|
|
91
|
+
# Migrate: backfill slug for entries missing it (detect from git remote)
|
|
92
|
+
local needs_slug
|
|
93
|
+
needs_slug=$(jq '[.initialized_repos[] | select(.slug == null or .slug == "")] | length' "$REPOS_FILE" 2>/dev/null) || needs_slug="0"
|
|
94
|
+
if [[ "$needs_slug" -gt 0 ]]; then
|
|
95
|
+
local temp_file="${REPOS_FILE}.tmp"
|
|
96
|
+
local repo_path slug
|
|
97
|
+
# Build a map of path->slug for repos missing slugs
|
|
98
|
+
while IFS= read -r repo_path; do
|
|
99
|
+
# Expand ~ to $HOME for git operations
|
|
100
|
+
local expanded_path="${repo_path/#\~/$HOME}"
|
|
101
|
+
slug=$(get_repo_slug "$expanded_path" 2>/dev/null) || slug=""
|
|
102
|
+
if [[ -n "$slug" ]]; then
|
|
103
|
+
jq --arg path "$repo_path" --arg slug "$slug" \
|
|
104
|
+
'(.initialized_repos[] | select(.path == $path and (.slug == null or .slug == ""))) |= . + {slug: $slug}' \
|
|
105
|
+
"$REPOS_FILE" >"$temp_file" && mv "$temp_file" "$REPOS_FILE"
|
|
106
|
+
fi
|
|
107
|
+
done < <(jq -r '.initialized_repos[] | select(.slug == null or .slug == "") | .path' "$REPOS_FILE" 2>/dev/null)
|
|
108
|
+
fi
|
|
91
109
|
fi
|
|
92
110
|
return 0
|
|
93
111
|
}
|
|
94
112
|
|
|
113
|
+
# Detect GitHub slug (owner/repo) from git remote origin
|
|
114
|
+
# Usage: get_repo_slug <path>
|
|
115
|
+
get_repo_slug() {
|
|
116
|
+
local repo_path="$1"
|
|
117
|
+
local remote_url
|
|
118
|
+
remote_url=$(git -C "$repo_path" remote get-url origin 2>/dev/null) || return 1
|
|
119
|
+
# Strip protocol/host prefix and .git suffix to get owner/repo
|
|
120
|
+
local slug
|
|
121
|
+
slug=$(echo "$remote_url" | sed 's|.*github\.com[:/]||;s|\.git$||')
|
|
122
|
+
if [[ -n "$slug" && "$slug" == *"/"* ]]; then
|
|
123
|
+
echo "$slug"
|
|
124
|
+
return 0
|
|
125
|
+
fi
|
|
126
|
+
return 1
|
|
127
|
+
}
|
|
128
|
+
|
|
95
129
|
# Register a repo in repos.json
|
|
96
130
|
# Usage: register_repo <path> <version> <features>
|
|
97
131
|
register_repo() {
|
|
@@ -112,18 +146,43 @@ register_repo() {
|
|
|
112
146
|
return 0
|
|
113
147
|
fi
|
|
114
148
|
|
|
149
|
+
# Auto-detect GitHub slug from git remote
|
|
150
|
+
local slug=""
|
|
151
|
+
local is_local_only="false"
|
|
152
|
+
if ! slug=$(get_repo_slug "$repo_path" 2>/dev/null); then
|
|
153
|
+
slug=""
|
|
154
|
+
# No remote origin — mark as local_only
|
|
155
|
+
if ! git -C "$repo_path" remote get-url origin &>/dev/null; then
|
|
156
|
+
is_local_only="true"
|
|
157
|
+
fi
|
|
158
|
+
fi
|
|
159
|
+
|
|
115
160
|
# Check if repo already registered
|
|
116
161
|
if jq -e --arg path "$repo_path" '.initialized_repos[] | select(.path == $path)' "$REPOS_FILE" &>/dev/null; then
|
|
117
|
-
# Update existing entry
|
|
162
|
+
# Update existing entry, preserving pulse/priority/local_only if already set
|
|
118
163
|
local temp_file="${REPOS_FILE}.tmp"
|
|
119
164
|
jq --arg path "$repo_path" --arg version "$version" --arg features "$features" \
|
|
120
|
-
|
|
165
|
+
--arg slug "$slug" --argjson local_only "$is_local_only" \
|
|
166
|
+
'(.initialized_repos[] | select(.path == $path)) |= (
|
|
167
|
+
. + {path: $path, version: $version, features: ($features | split(",")), updated: (now | strftime("%Y-%m-%dT%H:%M:%SZ"))}
|
|
168
|
+
| if $slug != "" then .slug = $slug else . end
|
|
169
|
+
| if $local_only then .local_only = true else . end
|
|
170
|
+
)' \
|
|
121
171
|
"$REPOS_FILE" >"$temp_file" && mv "$temp_file" "$REPOS_FILE"
|
|
122
172
|
else
|
|
123
|
-
# Add new entry
|
|
173
|
+
# Add new entry with slug
|
|
124
174
|
local temp_file="${REPOS_FILE}.tmp"
|
|
125
|
-
|
|
126
|
-
|
|
175
|
+
local new_entry
|
|
176
|
+
# shellcheck disable=SC2016 # jq expressions use $var syntax, not shell expansion
|
|
177
|
+
if [[ -n "$slug" ]]; then
|
|
178
|
+
new_entry='{path: $path, slug: $slug, version: $version, features: ($features | split(",")), initialized: (now | strftime("%Y-%m-%dT%H:%M:%SZ"))}'
|
|
179
|
+
elif [[ "$is_local_only" == "true" ]]; then
|
|
180
|
+
new_entry='{path: $path, local_only: true, version: $version, features: ($features | split(",")), initialized: (now | strftime("%Y-%m-%dT%H:%M:%SZ"))}'
|
|
181
|
+
else
|
|
182
|
+
new_entry='{path: $path, version: $version, features: ($features | split(",")), initialized: (now | strftime("%Y-%m-%dT%H:%M:%SZ"))}'
|
|
183
|
+
fi
|
|
184
|
+
jq --arg path "$repo_path" --arg version "$version" --arg features "$features" --arg slug "$slug" \
|
|
185
|
+
".initialized_repos += [$new_entry]" \
|
|
127
186
|
"$REPOS_FILE" >"$temp_file" && mv "$temp_file" "$REPOS_FILE"
|
|
128
187
|
fi
|
|
129
188
|
return 0
|
package/package.json
CHANGED
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: 2.
|
|
13
|
+
# Version: 2.137.0
|
|
14
14
|
#
|
|
15
15
|
# Quick Install:
|
|
16
16
|
# npm install -g aidevops && aidevops update (recommended)
|
|
@@ -533,6 +533,7 @@ main() {
|
|
|
533
533
|
migrate_loop_state_directories
|
|
534
534
|
migrate_agent_to_agents_folder
|
|
535
535
|
migrate_mcp_env_to_credentials
|
|
536
|
+
migrate_pulse_repos_to_repos_json
|
|
536
537
|
cleanup_deprecated_paths
|
|
537
538
|
cleanup_deprecated_mcps
|
|
538
539
|
cleanup_stale_bun_opencode
|
|
@@ -585,6 +586,7 @@ main() {
|
|
|
585
586
|
confirm_step "Migrate loop state from .claude/.agent/ to .agents/loop-state/" && migrate_loop_state_directories
|
|
586
587
|
confirm_step "Migrate .agent -> .agents in user projects" && migrate_agent_to_agents_folder
|
|
587
588
|
confirm_step "Migrate mcp-env.sh -> credentials.sh" && migrate_mcp_env_to_credentials
|
|
589
|
+
confirm_step "Migrate pulse-repos.json into repos.json" && migrate_pulse_repos_to_repos_json
|
|
588
590
|
confirm_step "Cleanup deprecated agent paths" && cleanup_deprecated_paths
|
|
589
591
|
confirm_step "Cleanup deprecated MCP entries (hetzner, serper, etc.)" && cleanup_deprecated_mcps
|
|
590
592
|
confirm_step "Cleanup stale bun opencode install" && cleanup_stale_bun_opencode
|