From 6473602f056d349285015016da73c156c570d9c3 Mon Sep 17 00:00:00 2001 From: gabrielmoro Date: Fri, 19 Jun 2026 10:07:57 -0300 Subject: [PATCH 1/3] adding kotzilla mcp --- opencode.json | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/opencode.json b/opencode.json index 61966d80..8b855796 100644 --- a/opencode.json +++ b/opencode.json @@ -3,5 +3,13 @@ "instructions": ["AGENTS.md"], "skills": { "paths": [".opencode/skills"] + }, + "mcp": { + "kotzilla": { + "type": "remote", + "url": "https://mcp.kotzilla.io/mcp", + "enabled": true, + "oauth": {} + } } } From d6cbb1c70c904e2a6851dfe6b9c4ef405ff09e12 Mon Sep 17 00:00:00 2001 From: gabrielmoro Date: Fri, 19 Jun 2026 11:02:18 -0300 Subject: [PATCH 2/3] add: update opencode.json and README files to include Maestro MCP configuration and documentation --- README.md | 32 ++++++++++++++++++++++++++++++++ README_pt-br.md | 32 ++++++++++++++++++++++++++++++++ opencode.json | 5 +++++ 3 files changed, 69 insertions(+) diff --git a/README.md b/README.md index cf26ea20..8259b698 100644 --- a/README.md +++ b/README.md @@ -94,6 +94,38 @@ We have a section called `discussions`, this is hosted in our repository, so we This project exists thanks to all the people who contribute. +## 🤖 AI-Assisted Development + +This project uses [opencode](https://opencode.ai) as the AI coding assistant. The configuration is centralized in the following files: + +### AGENTS.md + +Referenced by `opencode.json` as the instructions file (`"instructions": ["AGENTS.md"]`), it provides the AI agent with comprehensive project context — including project overview, build system (Gradle 9.3.1, Kotlin 2.3.20), module structure, key dependencies, version management, CI workflow, and contribution conventions. + +### opencode.json + +The root configuration file that orchestrates AI assistance: + +| Setting | Value | +|---|---| +| Instructions | `AGENTS.md` | +| Skills path | `.opencode/skills/` | + +### Skills + +Custom skills are located in `.opencode/skills/`. Currently available: + +- **open-pr** — Automates GitHub PR creation comparing the current feature branch against `master`, generating the PR description in Brazilian Portuguese (pt-br). + +### MCPs (Model Context Protocol) + +MCPs extend the AI's capabilities with external tools. Currently configured: + +| MCP | Type | Purpose | +|---|---|---| +| [Kotzilla](https://kotzilla.io) | Remote | Performance monitoring, dependency diagnosis (Koin), startup/ANR/crash analysis | +| [Maestro](https://maestro.mobile.dev) | Local (`maestro mcp`) | Mobile UI test automation and device interaction | + ## License Copyright 2023 Rodrigo Vianna diff --git a/README_pt-br.md b/README_pt-br.md index 77c369af..e4f7ea53 100644 --- a/README_pt-br.md +++ b/README_pt-br.md @@ -95,6 +95,38 @@ Criei um `discussions` e la além de ficar no histórico, se quiser olhar o exem Este projeto existe graças a todas as pessoas que contribuem. +## 🤖 Desenvolvimento Assistido por IA + +Este projeto utiliza o [opencode](https://opencode.ai) como assistente de codificação com IA. A configuração está centralizada nos seguintes arquivos: + +### AGENTS.md + +Referenciado pelo `opencode.json` como arquivo de instruções (`"instructions": ["AGENTS.md"]`), fornece ao agente de IA o contexto completo do projeto — incluindo visão geral, sistema de build (Gradle 9.3.1, Kotlin 2.3.20), estrutura de módulos, dependências principais, gerenciamento de versão, CI e convenções de contribuição. + +### opencode.json + +Arquivo raiz de configuração que orquestra a assistência de IA: + +| Configuração | Valor | +|---|---| +| Instructions | `AGENTS.md` | +| Skills path | `.opencode/skills/` | + +### Skills (Habilidades) + +Skills personalizadas estão em `.opencode/skills/`. Atualmente disponível: + +- **open-pr** — Automatiza a criação de PRs no GitHub comparando a branch atual com a `master`, gerando a descrição do PR em português brasileiro. + +### MCPs (Model Context Protocol) + +MCPs estendem as capacidades da IA com ferramentas externas. Atualmente configurados: + +| MCP | Tipo | Propósito | +|---|---|---| +| [Kotzilla](https://kotzilla.io) | Remoto | Monitoramento de performance, diagnóstico de dependências (Koin), análise de startup/ANR/crashes | +| [Maestro](https://maestro.mobile.dev) | Local (`maestro mcp`) | Automação de testes de UI mobile e interação com dispositivos | + ## License Copyright 2023 Rodrigo Vianna diff --git a/opencode.json b/opencode.json index 8b855796..f486b09d 100644 --- a/opencode.json +++ b/opencode.json @@ -10,6 +10,11 @@ "url": "https://mcp.kotzilla.io/mcp", "enabled": true, "oauth": {} + }, + "maestro": { + "type": "local", + "command": ["maestro", "mcp"], + "enabled": true } } } From 83a622440796f7488be47e645d19919dd19306e1 Mon Sep 17 00:00:00 2001 From: gabrielmoro Date: Fri, 19 Jun 2026 11:11:18 -0300 Subject: [PATCH 3/3] update ai files --- .opencode/skills/open-pr/SKILL.md | 72 +++++++++++++++++++------------ AGENTS.md | 13 ++++++ 2 files changed, 57 insertions(+), 28 deletions(-) diff --git a/.opencode/skills/open-pr/SKILL.md b/.opencode/skills/open-pr/SKILL.md index f1b36174..0479ef33 100644 --- a/.opencode/skills/open-pr/SKILL.md +++ b/.opencode/skills/open-pr/SKILL.md @@ -20,7 +20,18 @@ Open a Pull Request on GitHub comparing the current branch against `master`, gen git diff master...HEAD --stat ``` -4. **Categorize commits** by conventional commit type: +4. **Check for PR template** — look for a local PR template: + + ```bash + TEMPLATE_FILE=".github/PULL_REQUEST_TEMPLATE.md" + if [ -f "$TEMPLATE_FILE" ]; then + TEMPLATE_CONTENT=$(cat "$TEMPLATE_FILE") + else + TEMPLATE_CONTENT="" + fi + ``` + +5. **Categorize commits** by conventional commit type: | Type | Label | |---|---| @@ -33,7 +44,7 @@ Open a Pull Request on GitHub comparing the current branch against `master`, gen | `build` | Build / CI | | `BREAKING` | Mudança crítica | -5. **Identify affected modules** — from changed file paths, determine which modules were modified: +6. **Identify affected modules** — from changed file paths, determine which modules were modified: - `composeApp` - `feature-*` - `core-*` @@ -41,42 +52,46 @@ Open a Pull Request on GitHub comparing the current branch against `master`, gen - `androidApp` - `gradle` / config -6. **Generate PR body in pt-br** with the following structure: +7. **Generate PR body in pt-br** using the template if available: - ```markdown - ## O que foi feito? + - **If `TEMPLATE_CONTENT` is not empty:** use the template file as the base structure. Ensure all auto-generated content (commit summaries, module lists, etc.) is written in **pt-br**. If the template contains English section headers (e.g. `## What was done?`, `## How to test?`), translate them to pt-br equivalents (e.g. `## O que foi feito?`, `## Como testar?`). Inject the analyzed commits, affected modules, and test steps into the appropriate sections of the template. - [Resumo das alterações baseado nos commits] + - **If no template exists:** use the following hardcoded pt-br structure: - ## Módulos afetados + ```markdown + ## O que foi feito? - - [lista de módulos] + [Resumo das alterações baseado nos commits] - ## Tipo de mudança + ## Módulos afetados - - [ ] Nova funcionalidade - - [ ] Correção de bug - - [ ] Refatoração - - [ ] Documentação - - [ ] Testes - - [ ] Build / CI + - [lista de módulos] - ## Como testar? + ## Tipo de mudança - 1. [passos para testar] - 2. [passos adicionais] + - [ ] Nova funcionalidade + - [ ] Correção de bug + - [ ] Refatoração + - [ ] Documentação + - [ ] Testes + - [ ] Build / CI - ## Checklist + ## Como testar? - - [ ] Build passa localmente - - [ ] Lint / Detekt não aponta erros novos - - [ ] Testes existentes continuam passando - - [ ] Testes novos foram adicionados (se aplicável) - ``` + 1. [passos para testar] + 2. [passos adicionais] + + ## Checklist + + - [ ] Build passa localmente + - [ ] Lint / Detekt não aponta erros novos + - [ ] Testes existentes continuam passando + - [ ] Testes novos foram adicionados (se aplicável) + ``` -7. **Determine PR title** — use the first commit subject line or a concise summary derived from the branch name (e.g. `feat: adiciona tela de perfil`). +8. **Determine PR title** — use the first commit subject line or a concise summary derived from the branch name (e.g. `feat: adiciona tela de perfil`). -8. **Open the PR** using `gh`: +9. **Open the PR** using `gh`: ```bash gh pr create \ @@ -86,11 +101,12 @@ Open a Pull Request on GitHub comparing the current branch against `master`, gen --body "" ``` -9. If `gh` is not authenticated or available, print the full PR content to stdout with instructions. +10. If `gh` is not authenticated or available, print the full PR content to stdout with instructions. ## Notes -- All PR text MUST be in **pt-br** (Portuguese — Brazil). +- All PR text MUST be in **pt-br** (Portuguese — Brazil), regardless of whether a template is used. - Follow the project's existing commit style (conventional commits). - If the branch has only one commit, use its message as the PR title. - If the PR would be empty (no diff), warn the user. +- The skill looks for `.github/PULL_REQUEST_TEMPLATE.md` in the repo root. If found, its section structure is preserved but all injected content is in pt-br. If not found, a hardcoded pt-br template is used. diff --git a/AGENTS.md b/AGENTS.md index 9871a021..40343f11 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -16,6 +16,7 @@ | Kotlin | 2.3.20 | | AGP | 9.1.0 | | JDK | 21 | +| Kover | 0.9.1 | | Version Catalog | `gradle/libs.versions.toml` | | Convention Plugins | `build-logic/` (precompiled script plugins) | | Application ID | `com.codandotv.streamplayerapp` | @@ -38,6 +39,7 @@ - Navigation Compose 2.9.2 - Kotlinx Datetime 0.8.0 - Firebase (BOM 33.14.0, Crashlytics, Analytics) +- Kotzilla SDK 2.1.3 - Detekt 1.23.6 - Dokka 1.9.10 @@ -88,6 +90,7 @@ - Kotlinx Coroutines Test 1.8.1 - Koin Test - Popcorn Guinea Pig (test fixtures) +- Kover 0.9.1 (coverage reporting) ### Documentation @@ -95,6 +98,15 @@ - **Source:** API docs generated via `dokka` task - **Project docs:** README.md, README_pt-br.md +## MCP Tools + +| Tool | Type | Purpose | +|---|---|---| +| Kotzilla | Remote (`https://mcp.kotzilla.io/mcp`) | Performance monitoring, Koin diagnostics, app health reports | +| Maestro | Local (`maestro mcp`) | Mobile UI automation testing via Maestro flows | + +Configured in `opencode.json`. + ## Version Management Versions are managed in: @@ -115,6 +127,7 @@ This is an application project and is **not** published as a library. No Maven C |---|---| | Default Branch | `main` | | CI | GitHub Actions (`build.yml`, `linter.yaml`, `popcorn.yaml`) | +| Coverage | Kover HTML report deployed to GitHub Pages via `build.yml` | | Versioning | SemVer (current: 3.2) | | Tags | Standard Git tags | | PR Language | pt-br |