feat: externalize apps/analysis to Gitea repos, add analysis table
- Migration 007: repo_url on apps table + analysis table with FTS5 - Analysis struct, parser, CRUD, validation, hash computation - Selective purge: remote-only apps/analysis preserved across fn index - CLI: fn app list/clone/pull, fn analysis list/clone/pull - search/show/list now include analysis results - Apps removed from git tracking (content lives in Gitea repos) - .gitkeep for apps/ and analysis/ dirs - Bash functions: jupyter analysis pipeline, shell utilities - Browser domain: CDP functions moved from infra to browser Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
package infra
|
||||
package browser
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
@@ -2,13 +2,13 @@
|
||||
name: cdp_click
|
||||
kind: function
|
||||
lang: go
|
||||
domain: infra
|
||||
domain: browser
|
||||
version: "1.0.0"
|
||||
purity: impure
|
||||
signature: "func CdpClick(c *CDPConn, selector string) error"
|
||||
description: "Hace click en el primer elemento que coincide con el selector CSS. Obtiene coordenadas del centro via getBoundingClientRect, hace scroll al elemento y despacha eventos mousedown+mouseup via Input.dispatchMouseEvent."
|
||||
tags: [chrome, cdp, browser, automation, click, dom, devtools]
|
||||
uses_functions: [cdp_connect_go_infra, cdp_evaluate_go_infra]
|
||||
uses_functions: [cdp_connect_go_browser, cdp_evaluate_go_browser]
|
||||
uses_types: []
|
||||
returns: []
|
||||
returns_optional: false
|
||||
@@ -1,4 +1,4 @@
|
||||
package infra
|
||||
package browser
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
@@ -2,7 +2,7 @@
|
||||
name: cdp_close
|
||||
kind: function
|
||||
lang: go
|
||||
domain: infra
|
||||
domain: browser
|
||||
version: "1.0.0"
|
||||
purity: impure
|
||||
signature: "func CdpClose(c *CDPConn, pid int) error"
|
||||
@@ -1,4 +1,4 @@
|
||||
package infra
|
||||
package browser
|
||||
|
||||
import (
|
||||
"bufio"
|
||||
@@ -1,4 +1,4 @@
|
||||
package infra
|
||||
package browser
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
@@ -2,7 +2,7 @@
|
||||
name: cdp_connect
|
||||
kind: function
|
||||
lang: go
|
||||
domain: infra
|
||||
domain: browser
|
||||
version: "1.0.0"
|
||||
purity: impure
|
||||
signature: "func CdpConnect(port int) (*CDPConn, error)"
|
||||
@@ -1,4 +1,4 @@
|
||||
package infra
|
||||
package browser
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
@@ -2,13 +2,13 @@
|
||||
name: cdp_evaluate
|
||||
kind: function
|
||||
lang: go
|
||||
domain: infra
|
||||
domain: browser
|
||||
version: "1.0.0"
|
||||
purity: impure
|
||||
signature: "func CdpEvaluate(c *CDPConn, expression string) (string, error)"
|
||||
description: "Ejecuta una expresion JavaScript arbitraria en la pagina actual via Runtime.evaluate. Retorna el resultado serializado como string. Soporta await (awaitPromise=true). Reporta excepciones JS como error."
|
||||
tags: [chrome, cdp, browser, automation, javascript, devtools]
|
||||
uses_functions: [cdp_connect_go_infra]
|
||||
uses_functions: [cdp_connect_go_browser]
|
||||
uses_types: []
|
||||
returns: []
|
||||
returns_optional: false
|
||||
@@ -1,4 +1,4 @@
|
||||
package infra
|
||||
package browser
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
@@ -2,13 +2,13 @@
|
||||
name: cdp_get_html
|
||||
kind: function
|
||||
lang: go
|
||||
domain: infra
|
||||
domain: browser
|
||||
version: "1.0.0"
|
||||
purity: impure
|
||||
signature: "func CdpGetHTML(c *CDPConn) (string, error)"
|
||||
description: "Retorna el HTML completo de la pagina actual (document.documentElement.outerHTML) via Runtime.evaluate. Captura el DOM vivo post-JavaScript, no el HTML fuente original."
|
||||
tags: [chrome, cdp, browser, automation, html, dom, scraping, devtools]
|
||||
uses_functions: [cdp_connect_go_infra, cdp_evaluate_go_infra]
|
||||
uses_functions: [cdp_connect_go_browser, cdp_evaluate_go_browser]
|
||||
uses_types: []
|
||||
returns: []
|
||||
returns_optional: false
|
||||
@@ -1,4 +1,4 @@
|
||||
package infra
|
||||
package browser
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
@@ -2,13 +2,13 @@
|
||||
name: cdp_navigate
|
||||
kind: function
|
||||
lang: go
|
||||
domain: infra
|
||||
domain: browser
|
||||
version: "1.0.0"
|
||||
purity: impure
|
||||
signature: "func CdpNavigate(c *CDPConn, targetURL string) error"
|
||||
description: "Navega a la URL indicada usando el comando Page.navigate del protocolo CDP. Verifica que no haya errorText en la respuesta. Recibe una *CDPConn obtenida de CdpConnect."
|
||||
tags: [chrome, cdp, browser, automation, navigation, devtools]
|
||||
uses_functions: [cdp_connect_go_infra]
|
||||
uses_functions: [cdp_connect_go_browser]
|
||||
uses_types: []
|
||||
returns: []
|
||||
returns_optional: false
|
||||
@@ -1,4 +1,4 @@
|
||||
package infra
|
||||
package browser
|
||||
|
||||
import (
|
||||
"encoding/base64"
|
||||
@@ -2,13 +2,13 @@
|
||||
name: cdp_screenshot
|
||||
kind: function
|
||||
lang: go
|
||||
domain: infra
|
||||
domain: browser
|
||||
version: "1.0.0"
|
||||
purity: impure
|
||||
signature: "func CdpScreenshot(c *CDPConn, outputPath string, opts CdpScreenshotOpts) error"
|
||||
description: "Captura un screenshot de la pagina actual via Page.captureScreenshot y lo guarda en el archivo indicado. Soporta PNG y JPEG, viewport o pagina completa. Crea el directorio destino si no existe."
|
||||
tags: [chrome, cdp, browser, automation, screenshot, devtools, png]
|
||||
uses_functions: [cdp_connect_go_infra, cdp_evaluate_go_infra]
|
||||
uses_functions: [cdp_connect_go_browser, cdp_evaluate_go_browser]
|
||||
uses_types: []
|
||||
returns: []
|
||||
returns_optional: false
|
||||
@@ -1,4 +1,4 @@
|
||||
package infra
|
||||
package browser
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
@@ -2,13 +2,13 @@
|
||||
name: cdp_type_text
|
||||
kind: function
|
||||
lang: go
|
||||
domain: infra
|
||||
domain: browser
|
||||
version: "1.0.0"
|
||||
purity: impure
|
||||
signature: "func CdpTypeText(c *CDPConn, text string) error"
|
||||
description: "Escribe texto en el elemento activo de la pagina caracter por caracter via Input.dispatchKeyEvent. Envia eventos keyDown, char y keyUp por cada caracter con 10ms de pausa entre ellos. Usar CdpClick primero para enfocar el elemento."
|
||||
tags: [chrome, cdp, browser, automation, keyboard, input, devtools]
|
||||
uses_functions: [cdp_connect_go_infra]
|
||||
uses_functions: [cdp_connect_go_browser]
|
||||
uses_types: []
|
||||
returns: []
|
||||
returns_optional: false
|
||||
@@ -1,4 +1,4 @@
|
||||
package infra
|
||||
package browser
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
@@ -2,13 +2,13 @@
|
||||
name: cdp_wait_element
|
||||
kind: function
|
||||
lang: go
|
||||
domain: infra
|
||||
domain: browser
|
||||
version: "1.0.0"
|
||||
purity: impure
|
||||
signature: "func CdpWaitElement(c *CDPConn, selector string, timeout time.Duration) error"
|
||||
description: "Espera hasta que un selector CSS exista en el DOM. Hace polling con Runtime.evaluate cada 200ms. Retorna nil cuando el elemento aparece o error si se agota el timeout. Util despues de navegacion o acciones que producen cambios dinamicos."
|
||||
tags: [chrome, cdp, browser, automation, dom, wait, polling, devtools]
|
||||
uses_functions: [cdp_connect_go_infra, cdp_evaluate_go_infra]
|
||||
uses_functions: [cdp_connect_go_browser, cdp_evaluate_go_browser]
|
||||
uses_types: []
|
||||
returns: []
|
||||
returns_optional: false
|
||||
@@ -1,4 +1,4 @@
|
||||
package infra
|
||||
package browser
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
@@ -2,13 +2,13 @@
|
||||
name: cdp_wait_load
|
||||
kind: function
|
||||
lang: go
|
||||
domain: infra
|
||||
domain: browser
|
||||
version: "1.0.0"
|
||||
purity: impure
|
||||
signature: "func CdpWaitLoad(c *CDPConn, timeout time.Duration) error"
|
||||
description: "Espera a que la pagina actual termine de cargar completamente. Hace polling de document.readyState via Runtime.evaluate cada 200ms hasta que sea \"complete\", o hasta que se agote el timeout. Retorna error inmediato si CdpEvaluate falla (la conexion puede estar rota)."
|
||||
tags: [chrome, cdp, browser, automation, wait, polling, devtools, readystate, load]
|
||||
uses_functions: [cdp_evaluate_go_infra]
|
||||
uses_functions: [cdp_evaluate_go_browser]
|
||||
uses_types: []
|
||||
returns: []
|
||||
returns_optional: false
|
||||
@@ -1,4 +1,4 @@
|
||||
package infra
|
||||
package browser
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
@@ -2,7 +2,7 @@
|
||||
name: chrome_launch
|
||||
kind: function
|
||||
lang: go
|
||||
domain: infra
|
||||
domain: browser
|
||||
version: "1.0.0"
|
||||
purity: impure
|
||||
signature: "func ChromeLaunch(opts ChromeLaunchOpts) (int, error)"
|
||||
@@ -1,4 +1,4 @@
|
||||
package infra
|
||||
package browser
|
||||
|
||||
import (
|
||||
"os"
|
||||
Reference in New Issue
Block a user