aidevops 2.100.4 → 2.100.6

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
- 2.100.4
1
+ 2.100.6
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.100.4
6
+ # Version: 2.100.6
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": "2.100.4",
3
+ "version": "2.100.6",
4
4
  "description": "AI DevOps Framework - AI-assisted development workflows, code quality, and deployment automation",
5
5
  "type": "module",
6
6
  "main": "index.js",
package/setup.sh CHANGED
@@ -3,7 +3,7 @@
3
3
  # AI Assistant Server Access Framework Setup Script
4
4
  # Helps developers set up the framework for their infrastructure
5
5
  #
6
- # Version: 2.100.4
6
+ # Version: 2.100.6
7
7
  #
8
8
  # Quick Install (one-liner):
9
9
  # bash <(curl -fsSL https://aidevops.dev/install)
@@ -28,6 +28,23 @@ print_success() { echo -e "${GREEN}[SUCCESS]${NC} $1"; }
28
28
  print_warning() { echo -e "${YELLOW}[WARNING]${NC} $1"; }
29
29
  print_error() { echo -e "${RED}[ERROR]${NC} $1"; }
30
30
 
31
+ # Find OpenCode config file (checks multiple possible locations)
32
+ # Returns: path to config file, or empty string if not found
33
+ find_opencode_config() {
34
+ local candidates=(
35
+ "$HOME/.config/opencode/opencode.json" # XDG standard (Linux, some macOS)
36
+ "$HOME/.opencode/opencode.json" # Alternative location
37
+ "$HOME/Library/Application Support/opencode/opencode.json" # macOS standard
38
+ )
39
+ for candidate in "${candidates[@]}"; do
40
+ if [[ -f "$candidate" ]]; then
41
+ echo "$candidate"
42
+ return 0
43
+ fi
44
+ done
45
+ return 1
46
+ }
47
+
31
48
  # Find best python3 binary (prefer Homebrew/pyenv over system)
32
49
  find_python3() {
33
50
  local candidates=(
@@ -174,7 +191,8 @@ cleanup_deprecated_paths() {
174
191
  # Remove deprecated MCP entries from opencode.json
175
192
  # These MCPs have been replaced by curl-based subagents (zero context cost)
176
193
  cleanup_deprecated_mcps() {
177
- local opencode_config="$HOME/.config/opencode/opencode.json"
194
+ local opencode_config
195
+ opencode_config=$(find_opencode_config) || return 0
178
196
 
179
197
  if [[ ! -f "$opencode_config" ]]; then
180
198
  return 0
@@ -309,7 +327,8 @@ cleanup_deprecated_mcps() {
309
327
  # - google-analytics-mcp: ~800 tokens - enable via @google-analytics subagent
310
328
  # - context7: ~800 tokens - enable via @context7 subagent (for library docs lookup)
311
329
  disable_ondemand_mcps() {
312
- local opencode_config="$HOME/.config/opencode/opencode.json"
330
+ local opencode_config
331
+ opencode_config=$(find_opencode_config) || return 0
313
332
 
314
333
  if [[ ! -f "$opencode_config" ]]; then
315
334
  return 0
@@ -2053,13 +2072,14 @@ inject_agents_reference() {
2053
2072
  update_opencode_config() {
2054
2073
  print_info "Updating OpenCode configuration..."
2055
2074
 
2056
- local opencode_config="$HOME/.config/opencode/opencode.json"
2057
-
2058
- if [[ ! -f "$opencode_config" ]]; then
2059
- print_info "OpenCode config not found at $opencode_config - skipping"
2075
+ local opencode_config
2076
+ if ! opencode_config=$(find_opencode_config); then
2077
+ print_info "OpenCode config not found (checked ~/.config/opencode/, ~/.opencode/, ~/Library/Application Support/opencode/) - skipping"
2060
2078
  return 0
2061
2079
  fi
2062
2080
 
2081
+ print_info "Found OpenCode config at: $opencode_config"
2082
+
2063
2083
  # Create backup (with rotation)
2064
2084
  create_backup_with_rotation "$opencode_config" "opencode"
2065
2085
 
@@ -2324,7 +2344,8 @@ resolve_mcp_binary_path() {
2324
2344
  # Update opencode.json MCP commands to use full binary paths
2325
2345
  # This ensures MCPs start regardless of PATH configuration
2326
2346
  update_mcp_paths_in_opencode() {
2327
- local opencode_config="$HOME/.config/opencode/opencode.json"
2347
+ local opencode_config
2348
+ opencode_config=$(find_opencode_config) || return 0
2328
2349
 
2329
2350
  if [[ ! -f "$opencode_config" ]]; then
2330
2351
  return 0
@@ -2908,8 +2929,6 @@ add_opencode_plugin() {
2908
2929
  setup_opencode_plugins() {
2909
2930
  print_info "Setting up OpenCode plugins..."
2910
2931
 
2911
- local opencode_config="$HOME/.config/opencode/opencode.json"
2912
-
2913
2932
  # Check if OpenCode is installed
2914
2933
  if ! command -v opencode &> /dev/null; then
2915
2934
  print_warning "OpenCode not found - plugin setup skipped"
@@ -2918,8 +2937,9 @@ setup_opencode_plugins() {
2918
2937
  fi
2919
2938
 
2920
2939
  # Check if config exists
2921
- if [[ ! -f "$opencode_config" ]]; then
2922
- print_warning "OpenCode config not found at $opencode_config - plugin setup skipped"
2940
+ local opencode_config
2941
+ if ! opencode_config=$(find_opencode_config); then
2942
+ print_warning "OpenCode config not found - plugin setup skipped"
2923
2943
  return 0
2924
2944
  fi
2925
2945
 
@@ -2961,8 +2981,6 @@ setup_opencode_plugins() {
2961
2981
  setup_oh_my_opencode() {
2962
2982
  print_info "Setting up Oh-My-OpenCode plugin..."
2963
2983
 
2964
- local opencode_config="$HOME/.config/opencode/opencode.json"
2965
-
2966
2984
  # Check if OpenCode is installed
2967
2985
  if ! command -v opencode &> /dev/null; then
2968
2986
  print_warning "OpenCode not found - Oh-My-OpenCode setup skipped"
@@ -2970,7 +2988,8 @@ setup_oh_my_opencode() {
2970
2988
  fi
2971
2989
 
2972
2990
  # Check if config exists
2973
- if [[ ! -f "$opencode_config" ]]; then
2991
+ local opencode_config
2992
+ if ! opencode_config=$(find_opencode_config); then
2974
2993
  print_warning "OpenCode config not found - Oh-My-OpenCode setup skipped"
2975
2994
  return 0
2976
2995
  fi
@@ -3106,12 +3125,12 @@ setup_seo_mcps() {
3106
3125
  setup_google_analytics_mcp() {
3107
3126
  print_info "Setting up Google Analytics MCP..."
3108
3127
 
3109
- local opencode_config="$HOME/.config/opencode/opencode.json"
3110
3128
  local gsc_creds="$HOME/.config/aidevops/gsc-credentials.json"
3111
3129
 
3112
3130
  # Check if opencode.json exists
3113
- if [[ ! -f "$opencode_config" ]]; then
3114
- print_warning "OpenCode config not found at $opencode_config - skipping Google Analytics MCP"
3131
+ local opencode_config
3132
+ if ! opencode_config=$(find_opencode_config); then
3133
+ print_warning "OpenCode config not found - skipping Google Analytics MCP"
3115
3134
  return 0
3116
3135
  fi
3117
3136