chore: auto-commit (129 archivos)
- .claude/agents/fn-analizador/SKILL.md - .claude/agents/fn-constructor/SKILL.md - .claude/agents/fn-executor/SKILL.md - .claude/agents/fn-mejorador/SKILL.md - .claude/agents/fn-orquestador/SKILL.md - .claude/agents/fn-recopilador/SKILL.md - .claude/commands/app.md - .claude/commands/compile.md - .claude/commands/cpp-app.md - .claude/commands/create_functions.md - ... Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -38,7 +38,7 @@ if [[ -n "$matches" ]]; then
|
||||
fi
|
||||
|
||||
# Escanear repo especifico
|
||||
scan_secrets_in_dirty /home/lucas/fn_registry
|
||||
scan_secrets_in_dirty $HOME/fn_registry
|
||||
```
|
||||
|
||||
## Patrones detectados
|
||||
|
||||
@@ -22,14 +22,14 @@ params:
|
||||
- name: app_name
|
||||
desc: "Nombre de la app (ej: chart_demo). Se usa para localizar cpp/build/windows/apps/<app>/<app>.exe y el directorio destino Desktop/apps/<app>/."
|
||||
- name: app_dir
|
||||
desc: "Ruta absoluta al directorio fuente de la app (ej: /home/lucas/fn_registry/cpp/apps/chart_demo). Se usa para localizar enrichers/, runtime/ y app.md."
|
||||
desc: "Ruta absoluta al directorio fuente de la app (ej: $HOME/fn_registry/cpp/apps/chart_demo). Se usa para localizar enrichers/, runtime/ y app.md."
|
||||
output: "Copia archivos al escritorio de Windows. Imprime 'OK: <app> -> <dest>' en stdout. Si local_files/ existe, imprime su tamanio. Errores fatales a stderr con exit 1."
|
||||
---
|
||||
|
||||
## Ejemplo
|
||||
|
||||
```bash
|
||||
deploy_cpp_exe_to_windows "chart_demo" "/home/lucas/fn_registry/cpp/apps/chart_demo"
|
||||
deploy_cpp_exe_to_windows "chart_demo" "$HOME/fn_registry/cpp/apps/chart_demo"
|
||||
# OK: chart_demo -> /mnt/c/Users/lucas/Desktop/apps/chart_demo
|
||||
|
||||
# Con rutas custom via env vars
|
||||
@@ -55,7 +55,7 @@ Desktop/apps/<APP>/
|
||||
|
||||
- `BUILD_WIN` — directorio de build Windows; default `$FN_REGISTRY_ROOT/cpp/build/windows`
|
||||
- `WIN_DESKTOP_APPS` — directorio destino; default `/mnt/c/Users/lucas/Desktop/apps`
|
||||
- `FN_REGISTRY_ROOT` — raiz del registry; default `/home/lucas/fn_registry`
|
||||
- `FN_REGISTRY_ROOT` — raiz del registry; default `$HOME/fn_registry`
|
||||
|
||||
## Notas
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@ deploy_cpp_exe_to_windows() {
|
||||
return 1
|
||||
fi
|
||||
|
||||
local root="${FN_REGISTRY_ROOT:-/home/lucas/fn_registry}"
|
||||
local root="${FN_REGISTRY_ROOT:-$(cd "$(dirname "${BASH_SOURCE[0]}")/../../.." && pwd)}"
|
||||
local build_win="${BUILD_WIN:-$root/cpp/build/windows}"
|
||||
local win_desktop_apps="${WIN_DESKTOP_APPS:-/mnt/c/Users/lucas/Desktop/apps}"
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@ source bash/functions/infra/deploy_wails_exe_to_windows.sh
|
||||
|
||||
# Desplegar matrix_client_pc tras wails build -platform windows/amd64
|
||||
deploy_wails_exe_to_windows matrix_client_pc \
|
||||
/home/lucas/fn_registry/projects/element_agents/apps/matrix_client_pc
|
||||
$HOME/fn_registry/projects/element_agents/apps/matrix_client_pc
|
||||
```
|
||||
|
||||
Con override de destino:
|
||||
@@ -44,7 +44,7 @@ Con override de destino:
|
||||
```bash
|
||||
WIN_DESKTOP_APPS=/mnt/c/Users/lucas/Desktop/apps \
|
||||
deploy_wails_exe_to_windows matrix_admin_panel \
|
||||
/home/lucas/fn_registry/projects/element_agents/apps/matrix_admin_panel
|
||||
$HOME/fn_registry/projects/element_agents/apps/matrix_admin_panel
|
||||
```
|
||||
|
||||
## Cuando usarla
|
||||
|
||||
@@ -30,15 +30,15 @@ file_path: "bash/functions/infra/discover_git_repos.sh"
|
||||
source bash/functions/infra/discover_git_repos.sh
|
||||
|
||||
# Listar todos los repos bajo fn_registry
|
||||
discover_git_repos /home/lucas/fn_registry
|
||||
discover_git_repos $HOME/fn_registry
|
||||
|
||||
# Contar repos
|
||||
discover_git_repos /home/lucas/fn_registry | wc -l
|
||||
discover_git_repos $HOME/fn_registry | wc -l
|
||||
|
||||
# Iterar
|
||||
while IFS= read -r repo; do
|
||||
echo "Repo: $repo"
|
||||
done < <(discover_git_repos /home/lucas/fn_registry)
|
||||
done < <(discover_git_repos $HOME/fn_registry)
|
||||
```
|
||||
|
||||
## Notas
|
||||
|
||||
@@ -33,7 +33,7 @@ file_path: "bash/functions/infra/docker_cp_file.sh"
|
||||
```bash
|
||||
source functions/infra/docker_cp_file.sh
|
||||
|
||||
result=$(docker_cp_file /home/lucas/fn_registry/registry.db metabase /registry.db)
|
||||
result=$(docker_cp_file $HOME/fn_registry/registry.db metabase /registry.db)
|
||||
echo "$result"
|
||||
# {"local_size":524288,"remote_size":524288}
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ file_path: "bash/functions/infra/git_auto_commit_dirty.sh"
|
||||
source bash/functions/infra/git_auto_commit_dirty.sh
|
||||
|
||||
# Commitear con mensaje automatico
|
||||
subject=$(git_auto_commit_dirty /home/lucas/fn_registry)
|
||||
subject=$(git_auto_commit_dirty $HOME/fn_registry)
|
||||
echo "Commit: $subject"
|
||||
|
||||
# Commitear con mensaje fijo
|
||||
|
||||
@@ -17,7 +17,7 @@ error_type: "error_go_core"
|
||||
imports: []
|
||||
example: |
|
||||
# Manual check
|
||||
bash bash/functions/infra/git_hook_audit_app_drift.sh /home/lucas/fn_registry/apps/kanban
|
||||
bash bash/functions/infra/git_hook_audit_app_drift.sh $HOME/fn_registry/apps/kanban
|
||||
|
||||
# Used by pre_commit_hook_install_bash_infra (v2 hook chain)
|
||||
file_path: bash/functions/infra/git_hook_audit_app_drift.sh
|
||||
|
||||
@@ -30,7 +30,7 @@ file_path: "bash/functions/infra/git_pull_with_stash.sh"
|
||||
source bash/functions/infra/git_pull_with_stash.sh
|
||||
|
||||
# Pullear repo con auto-stash
|
||||
status=$(git_pull_with_stash /home/lucas/fn_registry)
|
||||
status=$(git_pull_with_stash $HOME/fn_registry)
|
||||
echo "$status"
|
||||
# [pulled] fn_registry
|
||||
# o:
|
||||
@@ -46,7 +46,7 @@ while IFS= read -r repo; do
|
||||
if [[ "$result" == "[diverged]"* || "$result" == "[stash-conflict]"* ]]; then
|
||||
diverged+=("$result")
|
||||
fi
|
||||
done < <(discover_git_repos /home/lucas/fn_registry)
|
||||
done < <(discover_git_repos $HOME/fn_registry)
|
||||
|
||||
if [[ ${#diverged[@]} -gt 0 ]]; then
|
||||
echo "ATENCION: repos que requieren intervencion manual:"
|
||||
|
||||
@@ -30,7 +30,7 @@ file_path: "bash/functions/infra/git_push_if_ahead.sh"
|
||||
source bash/functions/infra/git_push_if_ahead.sh
|
||||
|
||||
# Pushear si hay commits locales
|
||||
status=$(git_push_if_ahead /home/lucas/fn_registry)
|
||||
status=$(git_push_if_ahead $HOME/fn_registry)
|
||||
echo "$status"
|
||||
# [push] fn_registry (master, 3 commits ahead)
|
||||
# o:
|
||||
@@ -39,7 +39,7 @@ echo "$status"
|
||||
# Iterar sobre multiples repos
|
||||
while IFS= read -r repo; do
|
||||
git_push_if_ahead "$repo"
|
||||
done < <(discover_git_repos /home/lucas/fn_registry)
|
||||
done < <(discover_git_repos $HOME/fn_registry)
|
||||
```
|
||||
|
||||
## Estados de salida
|
||||
|
||||
@@ -61,7 +61,7 @@ Mitad complementaria de `deploy_cpp_exe_to_windows_bash_infra`. El flujo complet
|
||||
build_cpp_windows "registry_dashboard"
|
||||
|
||||
# 2. Copiar al escritorio (mata proceso si corre, copia DLLs+assets)
|
||||
deploy_cpp_exe_to_windows "registry_dashboard" "/home/lucas/fn_registry/apps/registry_dashboard"
|
||||
deploy_cpp_exe_to_windows "registry_dashboard" "$HOME/fn_registry/apps/registry_dashboard"
|
||||
|
||||
# 3. Lanzar
|
||||
launch_cpp_app_windows "registry_dashboard"
|
||||
|
||||
@@ -32,16 +32,16 @@ file_path: "bash/functions/infra/pre_commit_hook_install.sh"
|
||||
source bash/functions/infra/pre_commit_hook_install.sh
|
||||
|
||||
# Instalar en el repo actual
|
||||
pre_commit_hook_install /home/lucas/fn_registry
|
||||
# INSTALLED /home/lucas/fn_registry/.git/hooks/pre-commit
|
||||
pre_commit_hook_install $HOME/fn_registry
|
||||
# INSTALLED $HOME/fn_registry/.git/hooks/pre-commit
|
||||
|
||||
# Idempotente: segunda llamada no sobreescribe
|
||||
pre_commit_hook_install /home/lucas/fn_registry
|
||||
# SKIP /home/lucas/fn_registry/.git/hooks/pre-commit (already installed)
|
||||
pre_commit_hook_install $HOME/fn_registry
|
||||
# SKIP $HOME/fn_registry/.git/hooks/pre-commit (already installed)
|
||||
|
||||
# Forzar reinstalacion (hace backup del hook anterior)
|
||||
pre_commit_hook_install /home/lucas/fn_registry --force
|
||||
# INSTALLED /home/lucas/fn_registry/.git/hooks/pre-commit
|
||||
pre_commit_hook_install $HOME/fn_registry --force
|
||||
# INSTALLED $HOME/fn_registry/.git/hooks/pre-commit
|
||||
```
|
||||
|
||||
## Notas
|
||||
@@ -58,5 +58,5 @@ Si no puede localizar `fn_registry`, el hook imprime un aviso y sale con exit 0
|
||||
|
||||
Configurar `FN_REGISTRY_ROOT` en el perfil del shell para garantizar que el hook siempre encuentre el registry:
|
||||
```bash
|
||||
export FN_REGISTRY_ROOT=/home/lucas/fn_registry
|
||||
export FN_REGISTRY_ROOT=$HOME/fn_registry
|
||||
```
|
||||
|
||||
@@ -28,13 +28,13 @@ output: "Una linea TAB-separada '<app_name>\\t<absolute_dir_path>' en stdout. En
|
||||
|
||||
```bash
|
||||
# Desde dentro de cpp/apps/chart_demo/
|
||||
cd /home/lucas/fn_registry/cpp/apps/chart_demo
|
||||
cd $HOME/fn_registry/cpp/apps/chart_demo
|
||||
resolve_cpp_app_dir
|
||||
# -> chart_demo\t/home/lucas/fn_registry/cpp/apps/chart_demo
|
||||
# -> chart_demo\t$HOME/fn_registry/cpp/apps/chart_demo
|
||||
|
||||
# Con argumento explicito
|
||||
resolve_cpp_app_dir registry_dashboard
|
||||
# -> registry_dashboard\t/home/lucas/fn_registry/cpp/apps/registry_dashboard
|
||||
# -> registry_dashboard\t$HOME/fn_registry/cpp/apps/registry_dashboard
|
||||
|
||||
# Capturar los dos campos
|
||||
resolved=$(resolve_cpp_app_dir graph_explorer)
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
|
||||
resolve_cpp_app_dir() {
|
||||
local app_arg="${1:-}"
|
||||
local root="${FN_REGISTRY_ROOT:-/home/lucas/fn_registry}"
|
||||
local root="${FN_REGISTRY_ROOT:-$(cd "$(dirname "${BASH_SOURCE[0]}")/../../.." && pwd)}"
|
||||
|
||||
_list_cpp_apps() {
|
||||
ls "$root/apps/" 2>/dev/null | sed 's/^/ apps\//'
|
||||
|
||||
@@ -39,7 +39,7 @@ echo "$result"
|
||||
# {"files_transferred": 12, "total_size": "1.23 MB", "ssh_alias": "prod-server", "remote_dir": "/opt/apps/dag_engine"}
|
||||
|
||||
# Deploy con ruta absoluta local
|
||||
rsync_deploy "/home/lucas/fn_registry/apps/myapp/" "myserver" "/opt/myapp"
|
||||
rsync_deploy "$HOME/fn_registry/apps/myapp/" "myserver" "/opt/myapp"
|
||||
```
|
||||
|
||||
## Notas
|
||||
|
||||
@@ -30,7 +30,7 @@ file_path: "bash/functions/infra/write_mcp_jupyter_config.sh"
|
||||
|
||||
```bash
|
||||
source write_mcp_jupyter_config.sh
|
||||
path=$(write_mcp_jupyter_config /home/lucas/fn_registry/analysis/finanzas 8890)
|
||||
path=$(write_mcp_jupyter_config $HOME/fn_registry/analysis/finanzas 8890)
|
||||
echo "Config MCP en: $path"
|
||||
# Genera .mcp.json con:
|
||||
# "command": ".../.venv/bin/jupyter-mcp-server"
|
||||
|
||||
@@ -47,7 +47,7 @@ file_path: "bash/functions/pipelines/agent_scaffold.sh"
|
||||
|
||||
```bash
|
||||
# Crear agente basico con openai
|
||||
export FN_REGISTRY_ROOT=/home/lucas/fn_registry
|
||||
export FN_REGISTRY_ROOT=$HOME/fn_registry
|
||||
bash bash/functions/pipelines/agent_scaffold.sh monitor-bot \
|
||||
--display-name "Monitor Agent" \
|
||||
--description "Monitorea servicios y reporta estado" \
|
||||
|
||||
@@ -30,14 +30,14 @@ file_path: "bash/functions/pipelines/backup_all.sh"
|
||||
|
||||
```bash
|
||||
# Backup manual a ~/backups/fn_registry
|
||||
export FN_REGISTRY_ROOT=/home/lucas/fn_registry
|
||||
export FN_REGISTRY_ROOT=$HOME/fn_registry
|
||||
backup_all ~/backups/fn_registry
|
||||
|
||||
# Salida esperada:
|
||||
# 2026-05-07T10:30:00+02:00 registry=4194304B ops=3 vaults=2 partial_errors=0 elapsed=12s
|
||||
|
||||
# Entrada en crontab (diario a las 02:00)
|
||||
# 0 2 * * * FN_REGISTRY_ROOT=/home/lucas/fn_registry bash /home/lucas/fn_registry/bash/functions/pipelines/backup_all.sh ~/backups/fn_registry
|
||||
# 0 2 * * * FN_REGISTRY_ROOT=$HOME/fn_registry bash $HOME/fn_registry/bash/functions/pipelines/backup_all.sh ~/backups/fn_registry
|
||||
```
|
||||
|
||||
## Estructura de backup_root/
|
||||
|
||||
@@ -43,7 +43,7 @@ file_path: "bash/functions/pipelines/clone_project_subrepos.sh"
|
||||
# analysis domain_coverage_gaps [cloned]
|
||||
#
|
||||
# Siguiente paso sugerido:
|
||||
# cd /home/lucas/fn_registry && CGO_ENABLED=1 ./fn index && ./fn sync
|
||||
# cd $HOME/fn_registry && CGO_ENABLED=1 ./fn index && ./fn sync
|
||||
|
||||
# Con owner alternativo
|
||||
./fn run clone_project_subrepos aurgi --owner miorg
|
||||
@@ -65,7 +65,7 @@ Cuando llegas a un PC nuevo con solo fn_registry clonado y quieres trabajar en u
|
||||
|
||||
## Variables de entorno
|
||||
|
||||
- `FN_REGISTRY_ROOT` — raiz del registry; default `/home/lucas/fn_registry`
|
||||
- `FN_REGISTRY_ROOT` — raiz del registry; default `$HOME/fn_registry`
|
||||
- `GITEA_URL` — URL base de Gitea; default `https://gitea-dgg044oo04woo4ggcsws4gk0.organic-machine.com`
|
||||
- Auth git/ssh: el pipeline confía en la config local del usuario (SSH key, credential helper)
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ clone_project_subrepos() {
|
||||
fi
|
||||
|
||||
# --- Resolver paths ---
|
||||
local registry_root="${FN_REGISTRY_ROOT:-/home/lucas/fn_registry}"
|
||||
local registry_root="${FN_REGISTRY_ROOT:-$(cd "$(dirname "${BASH_SOURCE[0]}")/../../.." && pwd)}"
|
||||
local db="$registry_root/registry.db"
|
||||
local gitea_url="${GITEA_URL:-https://gitea-dgg044oo04woo4ggcsws4gk0.organic-machine.com}"
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ output: "Compila el .exe y lo despliega al escritorio de Windows. Imprime progre
|
||||
|
||||
```bash
|
||||
# Desde dentro del directorio de la app (sin arg)
|
||||
cd /home/lucas/fn_registry/cpp/apps/chart_demo
|
||||
cd $HOME/fn_registry/cpp/apps/chart_demo
|
||||
fn run compile_cpp_app
|
||||
|
||||
# Con nombre explicito desde cualquier directorio
|
||||
@@ -51,7 +51,7 @@ bash bash/functions/pipelines/compile_cpp_app.sh graph_explorer
|
||||
|
||||
## Variables de entorno
|
||||
|
||||
- `FN_REGISTRY_ROOT` — raiz del registry; default `/home/lucas/fn_registry`
|
||||
- `FN_REGISTRY_ROOT` — raiz del registry; default `$HOME/fn_registry`
|
||||
- `BUILD_WIN` — directorio de build Windows; default `$FN_REGISTRY_ROOT/cpp/build/windows`
|
||||
- `WIN_DESKTOP_APPS` — directorio destino; default `/mnt/c/Users/lucas/Desktop/apps`
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ compile_cpp_app() {
|
||||
deploy_cpp_exe_to_windows "$APP" "$APP_DIR"
|
||||
|
||||
# --- Resumen final ---
|
||||
local root="${FN_REGISTRY_ROOT:-/home/lucas/fn_registry}"
|
||||
local root="${FN_REGISTRY_ROOT:-$(cd "$SCRIPT_DIR/../../.." && pwd)}"
|
||||
local build_win="${BUILD_WIN:-$root/cpp/build/windows}"
|
||||
local win_desktop_apps="${WIN_DESKTOP_APPS:-/mnt/c/Users/lucas/Desktop/apps}"
|
||||
local final_exe="$win_desktop_apps/$APP/$APP.exe"
|
||||
|
||||
@@ -34,7 +34,7 @@ cd projects/element_agents/apps/matrix_client_pc
|
||||
./fn run compile_wails_app
|
||||
|
||||
# Desde la raiz del registry, con nombre explicito
|
||||
cd /home/lucas/fn_registry
|
||||
cd $HOME/fn_registry
|
||||
./fn run compile_wails_app matrix_admin_panel
|
||||
|
||||
# Directo sin fn run
|
||||
|
||||
@@ -63,7 +63,7 @@ file_path: "bash/functions/pipelines/dockerize_app.sh"
|
||||
|
||||
```bash
|
||||
# Deploy completo con basicAuth
|
||||
cd /home/lucas/fn_registry
|
||||
cd $HOME/fn_registry
|
||||
bash bash/functions/pipelines/dockerize_app.sh kanban \
|
||||
--domain kanban.organic-machine.com \
|
||||
--port 8421 \
|
||||
|
||||
@@ -46,7 +46,7 @@ bash bash/functions/pipelines/full_git_pull.sh
|
||||
|
||||
## Variables de entorno
|
||||
|
||||
- `FN_REGISTRY_ROOT` — raiz del registry; default `/home/lucas/fn_registry`
|
||||
- `FN_REGISTRY_ROOT` — raiz del registry; default `$HOME/fn_registry`
|
||||
- `FN_REGISTRY_API`, `REGISTRY_API_TOKEN` — se cargan de `pass registry/*`
|
||||
|
||||
## Notas
|
||||
|
||||
@@ -12,8 +12,9 @@ source "$INFRA_DIR/git_pull_with_stash.sh"
|
||||
source "$INFRA_DIR/pass_get.sh"
|
||||
|
||||
full_git_pull() {
|
||||
# Resolver raiz del registry
|
||||
local registry_root="${FN_REGISTRY_ROOT:-/home/lucas/fn_registry}"
|
||||
# Resolver raiz del registry. Deriva de SCRIPT_DIR (bash/functions/pipelines/)
|
||||
# para funcionar en cualquier PC sin path hardcodeado.
|
||||
local registry_root="${FN_REGISTRY_ROOT:-$(cd "$SCRIPT_DIR/../../.." && pwd)}"
|
||||
cd "$registry_root"
|
||||
|
||||
echo "=== full_git_pull: inicio ===" >&2
|
||||
|
||||
@@ -55,7 +55,7 @@ bash bash/functions/pipelines/full_git_push.sh "feat: nueva funcion"
|
||||
|
||||
## Variables de entorno
|
||||
|
||||
- `FN_REGISTRY_ROOT` — raiz del registry; default `/home/lucas/fn_registry`
|
||||
- `FN_REGISTRY_ROOT` — raiz del registry; default `$HOME/fn_registry`
|
||||
- `GITEA_URL`, `GITEA_TOKEN` — se cargan de `pass agentes/gitea-url` y `pass gitea/dataforge-git-token`
|
||||
- `FN_REGISTRY_API`, `REGISTRY_API_TOKEN` — se cargan de `pass registry/*`
|
||||
|
||||
|
||||
@@ -34,11 +34,11 @@ file_path: "bash/functions/pipelines/generate_capability_doc.sh"
|
||||
```bash
|
||||
# Regenerar tabla de notebook (ya existe, preserva Ejemplo canonico / Fronteras)
|
||||
./bash/functions/pipelines/generate_capability_doc.sh notebook
|
||||
# → /home/lucas/fn_registry/docs/capabilities/notebook.md updated (5 functions)
|
||||
# → $HOME/fn_registry/docs/capabilities/notebook.md updated (5 functions)
|
||||
|
||||
# Crear pagina nueva para un grupo sin pagina todavia
|
||||
./bash/functions/pipelines/generate_capability_doc.sh metabase
|
||||
# → /home/lucas/fn_registry/docs/capabilities/metabase.md created (12 functions)
|
||||
# → $HOME/fn_registry/docs/capabilities/metabase.md created (12 functions)
|
||||
|
||||
# Especificar registry y destino custom
|
||||
./bash/functions/pipelines/generate_capability_doc.sh android \
|
||||
@@ -49,7 +49,7 @@ file_path: "bash/functions/pipelines/generate_capability_doc.sh"
|
||||
# Grupo sin funciones todavia (avisa pero no falla)
|
||||
./bash/functions/pipelines/generate_capability_doc.sh nuevo_grupo
|
||||
# WARN: El grupo 'nuevo_grupo' no tiene funciones con ese tag en registry.db.
|
||||
# → /home/lucas/fn_registry/docs/capabilities/nuevo_grupo.md created (0 functions)
|
||||
# → $HOME/fn_registry/docs/capabilities/nuevo_grupo.md created (0 functions)
|
||||
```
|
||||
|
||||
## Comportamiento detallado
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
REGISTRY_ROOT="${FN_REGISTRY_ROOT:-/home/lucas/fn_registry}"
|
||||
REGISTRY_ROOT="${FN_REGISTRY_ROOT:-$(cd "$(dirname "${BASH_SOURCE[0]}")/../../.." && pwd)}"
|
||||
|
||||
# shellcheck disable=SC1091
|
||||
source "$REGISTRY_ROOT/bash/functions/infra/keepass_dump.sh"
|
||||
|
||||
@@ -27,7 +27,7 @@ params:
|
||||
- name: app_name
|
||||
desc: "Nombre de la app C++ (ej: chart_demo, registry_dashboard). Se usa para localizar el .exe en cpp/build/windows/apps/<app>/ y el destino Desktop/apps/<app>/."
|
||||
- name: app_dir
|
||||
desc: "Ruta absoluta al directorio fuente de la app (ej: /home/lucas/fn_registry/cpp/apps/chart_demo). Requerido para localizar enrichers/, runtime/ y app.md."
|
||||
desc: "Ruta absoluta al directorio fuente de la app (ej: $HOME/fn_registry/cpp/apps/chart_demo). Requerido para localizar enrichers/, runtime/ y app.md."
|
||||
- name: "--build"
|
||||
desc: "Flag opcional. Si presente, compila la app para Windows antes del deploy. Por defecto off (asume .exe ya compilado)."
|
||||
output: "Imprime 'OK: <app_name> redeployed (build=yes/no, PID=N)' en stdout. Exit 1 en cualquier paso fallido con mensaje de error indicando el paso."
|
||||
@@ -37,10 +37,10 @@ output: "Imprime 'OK: <app_name> redeployed (build=yes/no, PID=N)' en stdout. Ex
|
||||
|
||||
```bash
|
||||
# Solo redeploy (asume build ya hecho)
|
||||
redeploy_cpp_app_windows "registry_dashboard" "/home/lucas/fn_registry/projects/fn_monitoring/apps/registry_dashboard"
|
||||
redeploy_cpp_app_windows "registry_dashboard" "$HOME/fn_registry/projects/fn_monitoring/apps/registry_dashboard"
|
||||
|
||||
# Con build previo
|
||||
redeploy_cpp_app_windows "chart_demo" "/home/lucas/fn_registry/cpp/apps/chart_demo" --build
|
||||
redeploy_cpp_app_windows "chart_demo" "$HOME/fn_registry/cpp/apps/chart_demo" --build
|
||||
```
|
||||
|
||||
## Comportamiento
|
||||
|
||||
@@ -20,7 +20,7 @@ error_type: "error_go_core"
|
||||
imports: []
|
||||
params:
|
||||
- name: registry_db_path
|
||||
desc: "ruta a registry.db local (default: /home/lucas/fn_registry/registry.db)"
|
||||
desc: "ruta a registry.db local (default: $HOME/fn_registry/registry.db)"
|
||||
- name: container_name
|
||||
desc: "nombre del contenedor Metabase (default: metabase)"
|
||||
- name: dest_path
|
||||
@@ -40,7 +40,7 @@ file_path: "bash/functions/pipelines/setup_metabase_volume.sh"
|
||||
|
||||
# Con argumentos explícitos
|
||||
./functions/pipelines/setup_metabase_volume.sh \
|
||||
/home/lucas/fn_registry/registry.db \
|
||||
$HOME/fn_registry/registry.db \
|
||||
metabase \
|
||||
/registry.db
|
||||
```
|
||||
@@ -59,7 +59,7 @@ El pipeline usa `set -euo pipefail` — cualquier fallo en una función individu
|
||||
Las funciones individuales se sourcean desde sus rutas en el registry, relativas a `REGISTRY_ROOT` detectado automáticamente desde la ubicación del script.
|
||||
|
||||
Defaults:
|
||||
- `REGISTRY_DB_PATH`: `/home/lucas/fn_registry/registry.db`
|
||||
- `REGISTRY_DB_PATH`: `$HOME/fn_registry/registry.db`
|
||||
- `CONTAINER_NAME`: `metabase`
|
||||
- `DEST_PATH`: `/registry.db`
|
||||
|
||||
@@ -67,7 +67,7 @@ Nota de persistencia: `docker cp` copia al contenedor en ejecución. Si el conte
|
||||
|
||||
```yaml
|
||||
volumes:
|
||||
- /home/lucas/fn_registry:/fn_registry:ro
|
||||
- $HOME/fn_registry:/fn_registry:ro
|
||||
```
|
||||
|
||||
Y usar `--registry-db-path /fn_registry/registry.db`.
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
#
|
||||
# ARGUMENTOS (opcionales, con defaults):
|
||||
# REGISTRY_DB_PATH Ruta local al registry.db
|
||||
# Default: /home/lucas/fn_registry/registry.db
|
||||
# Default: <raiz_del_registry>/registry.db
|
||||
# CONTAINER_NAME Nombre del contenedor Docker de Metabase
|
||||
# Default: metabase
|
||||
# DEST_PATH Ruta destino dentro del contenedor
|
||||
@@ -26,7 +26,7 @@ source "$REGISTRY_ROOT/bash/functions/shell/assert_command_exists.sh"
|
||||
source "$REGISTRY_ROOT/bash/functions/infra/assert_docker_container_running.sh"
|
||||
source "$REGISTRY_ROOT/bash/functions/infra/docker_cp_file.sh"
|
||||
|
||||
REGISTRY_DB_PATH="${1:-/home/lucas/fn_registry/registry.db}"
|
||||
REGISTRY_DB_PATH="${1:-$REGISTRY_ROOT/registry.db}"
|
||||
CONTAINER_NAME="${2:-metabase}"
|
||||
DEST_PATH="${3:-/registry.db}"
|
||||
|
||||
|
||||
@@ -44,11 +44,11 @@ file_path: "bash/functions/pipelines/vault_audit.sh"
|
||||
|
||||
```bash
|
||||
# Auditar un vault especifico
|
||||
FN_REGISTRY_ROOT=/home/lucas/fn_registry \
|
||||
FN_REGISTRY_ROOT=$HOME/fn_registry \
|
||||
bash bash/functions/pipelines/vault_audit.sh turismo_spain
|
||||
|
||||
# Auditar todos los vaults
|
||||
FN_REGISTRY_ROOT=/home/lucas/fn_registry \
|
||||
FN_REGISTRY_ROOT=$HOME/fn_registry \
|
||||
bash bash/functions/pipelines/vault_audit.sh --all
|
||||
|
||||
# Solo layout + index + aggregate (sin profilers, mas rapido)
|
||||
|
||||
@@ -29,7 +29,7 @@ file_path: "bash/functions/shell/assert_file_exists.sh"
|
||||
```bash
|
||||
source functions/shell/assert_file_exists.sh
|
||||
|
||||
size=$(assert_file_exists /home/lucas/fn_registry/registry.db)
|
||||
size=$(assert_file_exists $HOME/fn_registry/registry.db)
|
||||
echo "Tamaño: $size bytes"
|
||||
```
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ file_path: "bash/functions/shell/validate_registry_paths.sh"
|
||||
|
||||
```bash
|
||||
source validate_registry_paths.sh
|
||||
validate_registry_paths /home/lucas/fn_registry/registry.db functions /home/lucas/fn_registry
|
||||
validate_registry_paths $HOME/fn_registry/registry.db functions $HOME/fn_registry
|
||||
|
||||
# Output (TSV):
|
||||
# cdp_click_go_browser functions/infra/cdp_click.go browser functions
|
||||
|
||||
Reference in New Issue
Block a user