javi-forge 0.1.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/.gitignore.template +105 -0
- package/.releaserc +44 -0
- package/README.md +45 -0
- package/ai-config/.skillignore +15 -0
- package/ai-config/AUTO_INVOKE.md +300 -0
- package/ai-config/agents/_TEMPLATE.md +93 -0
- package/ai-config/agents/business/api-designer.md +1657 -0
- package/ai-config/agents/business/business-analyst.md +1331 -0
- package/ai-config/agents/business/product-strategist.md +206 -0
- package/ai-config/agents/business/project-manager.md +178 -0
- package/ai-config/agents/business/requirements-analyst.md +1277 -0
- package/ai-config/agents/business/technical-writer.md +1679 -0
- package/ai-config/agents/creative/ux-designer.md +205 -0
- package/ai-config/agents/data-ai/ai-engineer.md +487 -0
- package/ai-config/agents/data-ai/analytics-engineer.md +953 -0
- package/ai-config/agents/data-ai/data-engineer.md +173 -0
- package/ai-config/agents/data-ai/data-scientist.md +672 -0
- package/ai-config/agents/data-ai/mlops-engineer.md +814 -0
- package/ai-config/agents/data-ai/prompt-engineer.md +772 -0
- package/ai-config/agents/development/angular-expert.md +620 -0
- package/ai-config/agents/development/backend-architect.md +795 -0
- package/ai-config/agents/development/database-specialist.md +212 -0
- package/ai-config/agents/development/frontend-specialist.md +686 -0
- package/ai-config/agents/development/fullstack-engineer.md +668 -0
- package/ai-config/agents/development/golang-pro.md +338 -0
- package/ai-config/agents/development/java-enterprise.md +400 -0
- package/ai-config/agents/development/javascript-pro.md +422 -0
- package/ai-config/agents/development/nextjs-pro.md +474 -0
- package/ai-config/agents/development/python-pro.md +570 -0
- package/ai-config/agents/development/react-pro.md +487 -0
- package/ai-config/agents/development/rust-pro.md +246 -0
- package/ai-config/agents/development/spring-boot-4-expert.md +326 -0
- package/ai-config/agents/development/typescript-pro.md +336 -0
- package/ai-config/agents/development/vue-specialist.md +605 -0
- package/ai-config/agents/infrastructure/cloud-architect.md +472 -0
- package/ai-config/agents/infrastructure/deployment-manager.md +358 -0
- package/ai-config/agents/infrastructure/devops-engineer.md +455 -0
- package/ai-config/agents/infrastructure/incident-responder.md +519 -0
- package/ai-config/agents/infrastructure/kubernetes-expert.md +705 -0
- package/ai-config/agents/infrastructure/monitoring-specialist.md +674 -0
- package/ai-config/agents/infrastructure/performance-engineer.md +658 -0
- package/ai-config/agents/orchestrator.md +241 -0
- package/ai-config/agents/quality/accessibility-auditor.md +1204 -0
- package/ai-config/agents/quality/code-reviewer-compact.md +123 -0
- package/ai-config/agents/quality/code-reviewer.md +363 -0
- package/ai-config/agents/quality/dependency-manager.md +743 -0
- package/ai-config/agents/quality/e2e-test-specialist.md +1005 -0
- package/ai-config/agents/quality/performance-tester.md +1086 -0
- package/ai-config/agents/quality/security-auditor.md +133 -0
- package/ai-config/agents/quality/test-engineer.md +453 -0
- package/ai-config/agents/specialists/api-designer.md +87 -0
- package/ai-config/agents/specialists/backend-architect.md +73 -0
- package/ai-config/agents/specialists/code-reviewer.md +77 -0
- package/ai-config/agents/specialists/db-optimizer.md +75 -0
- package/ai-config/agents/specialists/devops-engineer.md +83 -0
- package/ai-config/agents/specialists/documentation-writer.md +78 -0
- package/ai-config/agents/specialists/frontend-developer.md +75 -0
- package/ai-config/agents/specialists/performance-analyst.md +82 -0
- package/ai-config/agents/specialists/refactor-specialist.md +74 -0
- package/ai-config/agents/specialists/security-auditor.md +74 -0
- package/ai-config/agents/specialists/test-engineer.md +81 -0
- package/ai-config/agents/specialists/ux-consultant.md +76 -0
- package/ai-config/agents/specialized/agent-generator.md +1190 -0
- package/ai-config/agents/specialized/blockchain-developer.md +149 -0
- package/ai-config/agents/specialized/code-migrator.md +892 -0
- package/ai-config/agents/specialized/context-manager.md +978 -0
- package/ai-config/agents/specialized/documentation-writer.md +1078 -0
- package/ai-config/agents/specialized/ecommerce-expert.md +1756 -0
- package/ai-config/agents/specialized/embedded-engineer.md +1714 -0
- package/ai-config/agents/specialized/error-detective.md +1034 -0
- package/ai-config/agents/specialized/fintech-specialist.md +1659 -0
- package/ai-config/agents/specialized/freelance-project-planner-v2.md +1988 -0
- package/ai-config/agents/specialized/freelance-project-planner-v3.md +2136 -0
- package/ai-config/agents/specialized/freelance-project-planner-v4.md +4503 -0
- package/ai-config/agents/specialized/freelance-project-planner.md +722 -0
- package/ai-config/agents/specialized/game-developer.md +1963 -0
- package/ai-config/agents/specialized/healthcare-dev.md +1620 -0
- package/ai-config/agents/specialized/mobile-developer.md +188 -0
- package/ai-config/agents/specialized/parallel-plan-executor.md +506 -0
- package/ai-config/agents/specialized/plan-executor.md +485 -0
- package/ai-config/agents/specialized/solo-dev-planner-modular/00-INDEX.md +485 -0
- package/ai-config/agents/specialized/solo-dev-planner-modular/01-CORE.md +3493 -0
- package/ai-config/agents/specialized/solo-dev-planner-modular/02-SELF-CORRECTION.md +778 -0
- package/ai-config/agents/specialized/solo-dev-planner-modular/03-PROGRESSIVE-SETUP.md +918 -0
- package/ai-config/agents/specialized/solo-dev-planner-modular/04-DEPLOYMENT.md +1537 -0
- package/ai-config/agents/specialized/solo-dev-planner-modular/05-TESTING.md +2633 -0
- package/ai-config/agents/specialized/solo-dev-planner-modular/06-OPERATIONS.md +5610 -0
- package/ai-config/agents/specialized/solo-dev-planner-modular/INSTALL.md +335 -0
- package/ai-config/agents/specialized/solo-dev-planner-modular/QUICK-REFERENCE.txt +215 -0
- package/ai-config/agents/specialized/solo-dev-planner-modular/README.md +260 -0
- package/ai-config/agents/specialized/solo-dev-planner-modular/START-HERE.md +379 -0
- package/ai-config/agents/specialized/solo-dev-planner-modular/WORKFLOW-DIAGRAM.md +355 -0
- package/ai-config/agents/specialized/solo-dev-planner-modular/solo-dev-planner.md +279 -0
- package/ai-config/agents/specialized/template-writer.md +347 -0
- package/ai-config/agents/specialized/test-runner.md +99 -0
- package/ai-config/agents/specialized/vibekanban-smart-worker.md +244 -0
- package/ai-config/agents/specialized/wave-executor.md +138 -0
- package/ai-config/agents/specialized/workflow-optimizer.md +1114 -0
- package/ai-config/commands/git/changelog.md +32 -0
- package/ai-config/commands/git/ci-local.md +70 -0
- package/ai-config/commands/git/commit.md +35 -0
- package/ai-config/commands/git/fix-issue.md +23 -0
- package/ai-config/commands/git/pr-create.md +42 -0
- package/ai-config/commands/git/pr-review.md +50 -0
- package/ai-config/commands/git/worktree.md +39 -0
- package/ai-config/commands/refactoring/cleanup.md +24 -0
- package/ai-config/commands/refactoring/dead-code.md +40 -0
- package/ai-config/commands/refactoring/extract.md +31 -0
- package/ai-config/commands/testing/e2e.md +30 -0
- package/ai-config/commands/testing/tdd.md +36 -0
- package/ai-config/commands/testing/test-coverage.md +30 -0
- package/ai-config/commands/testing/test-fix.md +24 -0
- package/ai-config/commands/workflow/generate-agents-md.md +85 -0
- package/ai-config/commands/workflow/planning.md +47 -0
- package/ai-config/commands/workflows/compound.md +89 -0
- package/ai-config/commands/workflows/plan.md +77 -0
- package/ai-config/commands/workflows/review.md +78 -0
- package/ai-config/commands/workflows/work.md +75 -0
- package/ai-config/config.yaml +18 -0
- package/ai-config/hooks/_TEMPLATE.md +96 -0
- package/ai-config/hooks/block-dangerous-commands.md +75 -0
- package/ai-config/hooks/commit-guard.md +90 -0
- package/ai-config/hooks/context-loader.md +73 -0
- package/ai-config/hooks/improve-prompt.md +91 -0
- package/ai-config/hooks/learning-log.md +72 -0
- package/ai-config/hooks/model-router.md +86 -0
- package/ai-config/hooks/secret-scanner.md +64 -0
- package/ai-config/hooks/skill-validator.md +102 -0
- package/ai-config/hooks/task-artifact.md +114 -0
- package/ai-config/hooks/validate-workflow.md +100 -0
- package/ai-config/prompts/base.md +71 -0
- package/ai-config/prompts/modes/debug.md +34 -0
- package/ai-config/prompts/modes/deploy.md +40 -0
- package/ai-config/prompts/modes/research.md +32 -0
- package/ai-config/prompts/modes/review.md +33 -0
- package/ai-config/prompts/review-policy.md +79 -0
- package/ai-config/skills/_TEMPLATE.md +157 -0
- package/ai-config/skills/backend/api-gateway/SKILL.md +254 -0
- package/ai-config/skills/backend/bff-concepts/SKILL.md +239 -0
- package/ai-config/skills/backend/bff-spring/SKILL.md +364 -0
- package/ai-config/skills/backend/chi-router/SKILL.md +396 -0
- package/ai-config/skills/backend/error-handling/SKILL.md +255 -0
- package/ai-config/skills/backend/exceptions-spring/SKILL.md +323 -0
- package/ai-config/skills/backend/fastapi/SKILL.md +302 -0
- package/ai-config/skills/backend/gateway-spring/SKILL.md +390 -0
- package/ai-config/skills/backend/go-backend/SKILL.md +457 -0
- package/ai-config/skills/backend/gradle-multimodule/SKILL.md +274 -0
- package/ai-config/skills/backend/graphql-concepts/SKILL.md +352 -0
- package/ai-config/skills/backend/graphql-spring/SKILL.md +398 -0
- package/ai-config/skills/backend/grpc-concepts/SKILL.md +283 -0
- package/ai-config/skills/backend/grpc-spring/SKILL.md +445 -0
- package/ai-config/skills/backend/jwt-auth/SKILL.md +412 -0
- package/ai-config/skills/backend/notifications-concepts/SKILL.md +259 -0
- package/ai-config/skills/backend/recommendations-concepts/SKILL.md +261 -0
- package/ai-config/skills/backend/search-concepts/SKILL.md +263 -0
- package/ai-config/skills/backend/search-spring/SKILL.md +375 -0
- package/ai-config/skills/backend/spring-boot-4/SKILL.md +172 -0
- package/ai-config/skills/backend/websockets/SKILL.md +532 -0
- package/ai-config/skills/data-ai/ai-ml/SKILL.md +423 -0
- package/ai-config/skills/data-ai/analytics-concepts/SKILL.md +195 -0
- package/ai-config/skills/data-ai/analytics-spring/SKILL.md +340 -0
- package/ai-config/skills/data-ai/duckdb-analytics/SKILL.md +440 -0
- package/ai-config/skills/data-ai/langchain/SKILL.md +238 -0
- package/ai-config/skills/data-ai/mlflow/SKILL.md +302 -0
- package/ai-config/skills/data-ai/onnx-inference/SKILL.md +290 -0
- package/ai-config/skills/data-ai/powerbi/SKILL.md +352 -0
- package/ai-config/skills/data-ai/pytorch/SKILL.md +274 -0
- package/ai-config/skills/data-ai/scikit-learn/SKILL.md +321 -0
- package/ai-config/skills/data-ai/vector-db/SKILL.md +301 -0
- package/ai-config/skills/database/graph-databases/SKILL.md +218 -0
- package/ai-config/skills/database/graph-spring/SKILL.md +361 -0
- package/ai-config/skills/database/pgx-postgres/SKILL.md +512 -0
- package/ai-config/skills/database/redis-cache/SKILL.md +343 -0
- package/ai-config/skills/database/sqlite-embedded/SKILL.md +388 -0
- package/ai-config/skills/database/timescaledb/SKILL.md +320 -0
- package/ai-config/skills/docs/api-documentation/SKILL.md +293 -0
- package/ai-config/skills/docs/docs-spring/SKILL.md +377 -0
- package/ai-config/skills/docs/mustache-templates/SKILL.md +190 -0
- package/ai-config/skills/docs/technical-docs/SKILL.md +447 -0
- package/ai-config/skills/frontend/astro-ssr/SKILL.md +441 -0
- package/ai-config/skills/frontend/frontend-design/SKILL.md +54 -0
- package/ai-config/skills/frontend/frontend-web/SKILL.md +368 -0
- package/ai-config/skills/frontend/mantine-ui/SKILL.md +396 -0
- package/ai-config/skills/frontend/tanstack-query/SKILL.md +439 -0
- package/ai-config/skills/frontend/zod-validation/SKILL.md +417 -0
- package/ai-config/skills/frontend/zustand-state/SKILL.md +350 -0
- package/ai-config/skills/infrastructure/chaos-engineering/SKILL.md +244 -0
- package/ai-config/skills/infrastructure/chaos-spring/SKILL.md +378 -0
- package/ai-config/skills/infrastructure/devops-infra/SKILL.md +435 -0
- package/ai-config/skills/infrastructure/docker-containers/SKILL.md +420 -0
- package/ai-config/skills/infrastructure/kubernetes/SKILL.md +456 -0
- package/ai-config/skills/infrastructure/opentelemetry/SKILL.md +546 -0
- package/ai-config/skills/infrastructure/traefik-proxy/SKILL.md +474 -0
- package/ai-config/skills/infrastructure/woodpecker-ci/SKILL.md +315 -0
- package/ai-config/skills/mobile/ionic-capacitor/SKILL.md +504 -0
- package/ai-config/skills/mobile/mobile-ionic/SKILL.md +448 -0
- package/ai-config/skills/prompt-improver/SKILL.md +125 -0
- package/ai-config/skills/quality/ghagga-review/SKILL.md +216 -0
- package/ai-config/skills/references/hooks-patterns/SKILL.md +238 -0
- package/ai-config/skills/references/mcp-servers/SKILL.md +275 -0
- package/ai-config/skills/references/plugins-reference/SKILL.md +110 -0
- package/ai-config/skills/references/skills-reference/SKILL.md +420 -0
- package/ai-config/skills/references/subagent-templates/SKILL.md +193 -0
- package/ai-config/skills/systems-iot/modbus-protocol/SKILL.md +410 -0
- package/ai-config/skills/systems-iot/mqtt-rumqttc/SKILL.md +408 -0
- package/ai-config/skills/systems-iot/rust-systems/SKILL.md +386 -0
- package/ai-config/skills/systems-iot/tokio-async/SKILL.md +324 -0
- package/ai-config/skills/testing/playwright-e2e/SKILL.md +289 -0
- package/ai-config/skills/testing/testcontainers/SKILL.md +299 -0
- package/ai-config/skills/testing/vitest-testing/SKILL.md +381 -0
- package/ai-config/skills/workflow/ci-local-guide/SKILL.md +118 -0
- package/ai-config/skills/workflow/claude-automation-recommender/SKILL.md +299 -0
- package/ai-config/skills/workflow/claude-md-improver/SKILL.md +158 -0
- package/ai-config/skills/workflow/finishing-a-development-branch/SKILL.md +117 -0
- package/ai-config/skills/workflow/git-github/SKILL.md +334 -0
- package/ai-config/skills/workflow/git-github/references/examples.md +160 -0
- package/ai-config/skills/workflow/git-workflow/SKILL.md +214 -0
- package/ai-config/skills/workflow/ide-plugins/SKILL.md +277 -0
- package/ai-config/skills/workflow/ide-plugins-intellij/SKILL.md +401 -0
- package/ai-config/skills/workflow/obsidian-brain-workflow/SKILL.md +199 -0
- package/ai-config/skills/workflow/using-git-worktrees/SKILL.md +100 -0
- package/ai-config/skills/workflow/verification-before-completion/SKILL.md +73 -0
- package/ai-config/skills/workflow/wave-workflow/SKILL.md +178 -0
- package/ci-local/README.md +170 -0
- package/ci-local/ci-local.sh +297 -0
- package/ci-local/hooks/commit-msg +74 -0
- package/ci-local/hooks/pre-commit +162 -0
- package/ci-local/hooks/pre-push +41 -0
- package/ci-local/install.sh +49 -0
- package/ci-local/semgrep.yml +214 -0
- package/dist/commands/analyze.d.ts +9 -0
- package/dist/commands/analyze.d.ts.map +1 -0
- package/dist/commands/analyze.js +55 -0
- package/dist/commands/analyze.js.map +1 -0
- package/dist/commands/analyze.test.d.ts +2 -0
- package/dist/commands/analyze.test.d.ts.map +1 -0
- package/dist/commands/analyze.test.js +145 -0
- package/dist/commands/analyze.test.js.map +1 -0
- package/dist/commands/doctor.d.ts +7 -0
- package/dist/commands/doctor.d.ts.map +1 -0
- package/dist/commands/doctor.js +158 -0
- package/dist/commands/doctor.js.map +1 -0
- package/dist/commands/doctor.test.d.ts +2 -0
- package/dist/commands/doctor.test.d.ts.map +1 -0
- package/dist/commands/doctor.test.js +200 -0
- package/dist/commands/doctor.test.js.map +1 -0
- package/dist/commands/init.d.ts +9 -0
- package/dist/commands/init.d.ts.map +1 -0
- package/dist/commands/init.js +283 -0
- package/dist/commands/init.js.map +1 -0
- package/dist/commands/init.test.d.ts +2 -0
- package/dist/commands/init.test.d.ts.map +1 -0
- package/dist/commands/init.test.js +271 -0
- package/dist/commands/init.test.js.map +1 -0
- package/dist/commands/sync.d.ts +8 -0
- package/dist/commands/sync.d.ts.map +1 -0
- package/dist/commands/sync.js +201 -0
- package/dist/commands/sync.js.map +1 -0
- package/dist/constants.d.ts +21 -0
- package/dist/constants.d.ts.map +1 -0
- package/dist/constants.js +57 -0
- package/dist/constants.js.map +1 -0
- package/dist/e2e/aggressive.e2e.test.d.ts +2 -0
- package/dist/e2e/aggressive.e2e.test.d.ts.map +1 -0
- package/dist/e2e/aggressive.e2e.test.js +350 -0
- package/dist/e2e/aggressive.e2e.test.js.map +1 -0
- package/dist/e2e/commands.e2e.test.d.ts +2 -0
- package/dist/e2e/commands.e2e.test.d.ts.map +1 -0
- package/dist/e2e/commands.e2e.test.js +213 -0
- package/dist/e2e/commands.e2e.test.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +82 -0
- package/dist/index.js.map +1 -0
- package/dist/lib/common.d.ts +17 -0
- package/dist/lib/common.d.ts.map +1 -0
- package/dist/lib/common.js +111 -0
- package/dist/lib/common.js.map +1 -0
- package/dist/lib/common.test.d.ts +2 -0
- package/dist/lib/common.test.d.ts.map +1 -0
- package/dist/lib/common.test.js +316 -0
- package/dist/lib/common.test.js.map +1 -0
- package/dist/lib/frontmatter.d.ts +18 -0
- package/dist/lib/frontmatter.d.ts.map +1 -0
- package/dist/lib/frontmatter.js +61 -0
- package/dist/lib/frontmatter.js.map +1 -0
- package/dist/lib/frontmatter.test.d.ts +2 -0
- package/dist/lib/frontmatter.test.d.ts.map +1 -0
- package/dist/lib/frontmatter.test.js +257 -0
- package/dist/lib/frontmatter.test.js.map +1 -0
- package/dist/lib/template.d.ts +24 -0
- package/dist/lib/template.d.ts.map +1 -0
- package/dist/lib/template.js +78 -0
- package/dist/lib/template.js.map +1 -0
- package/dist/lib/template.test.d.ts +2 -0
- package/dist/lib/template.test.d.ts.map +1 -0
- package/dist/lib/template.test.js +201 -0
- package/dist/lib/template.test.js.map +1 -0
- package/dist/types/index.d.ts +48 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +2 -0
- package/dist/types/index.js.map +1 -0
- package/dist/ui/AnalyzeUI.d.ts +7 -0
- package/dist/ui/AnalyzeUI.d.ts.map +1 -0
- package/dist/ui/AnalyzeUI.js +100 -0
- package/dist/ui/AnalyzeUI.js.map +1 -0
- package/dist/ui/App.d.ts +13 -0
- package/dist/ui/App.d.ts.map +1 -0
- package/dist/ui/App.js +100 -0
- package/dist/ui/App.js.map +1 -0
- package/dist/ui/CIContext.d.ts +9 -0
- package/dist/ui/CIContext.d.ts.map +1 -0
- package/dist/ui/CIContext.js +9 -0
- package/dist/ui/CIContext.js.map +1 -0
- package/dist/ui/CISelector.d.ts +8 -0
- package/dist/ui/CISelector.d.ts.map +1 -0
- package/dist/ui/CISelector.js +45 -0
- package/dist/ui/CISelector.js.map +1 -0
- package/dist/ui/Doctor.d.ts +3 -0
- package/dist/ui/Doctor.d.ts.map +1 -0
- package/dist/ui/Doctor.js +89 -0
- package/dist/ui/Doctor.js.map +1 -0
- package/dist/ui/Header.d.ts +8 -0
- package/dist/ui/Header.d.ts.map +1 -0
- package/dist/ui/Header.js +30 -0
- package/dist/ui/Header.js.map +1 -0
- package/dist/ui/MemorySelector.d.ts +8 -0
- package/dist/ui/MemorySelector.d.ts.map +1 -0
- package/dist/ui/MemorySelector.js +46 -0
- package/dist/ui/MemorySelector.js.map +1 -0
- package/dist/ui/NameInput.d.ts +8 -0
- package/dist/ui/NameInput.d.ts.map +1 -0
- package/dist/ui/NameInput.js +69 -0
- package/dist/ui/NameInput.js.map +1 -0
- package/dist/ui/OptionSelector.d.ts +12 -0
- package/dist/ui/OptionSelector.d.ts.map +1 -0
- package/dist/ui/OptionSelector.js +69 -0
- package/dist/ui/OptionSelector.js.map +1 -0
- package/dist/ui/Progress.d.ts +11 -0
- package/dist/ui/Progress.d.ts.map +1 -0
- package/dist/ui/Progress.js +58 -0
- package/dist/ui/Progress.js.map +1 -0
- package/dist/ui/StackSelector.d.ts +9 -0
- package/dist/ui/StackSelector.d.ts.map +1 -0
- package/dist/ui/StackSelector.js +65 -0
- package/dist/ui/StackSelector.js.map +1 -0
- package/dist/ui/Summary.d.ts +12 -0
- package/dist/ui/Summary.d.ts.map +1 -0
- package/dist/ui/Summary.js +114 -0
- package/dist/ui/Summary.js.map +1 -0
- package/dist/ui/SyncUI.d.ts +10 -0
- package/dist/ui/SyncUI.d.ts.map +1 -0
- package/dist/ui/SyncUI.js +64 -0
- package/dist/ui/SyncUI.js.map +1 -0
- package/dist/ui/Welcome.d.ts +7 -0
- package/dist/ui/Welcome.d.ts.map +1 -0
- package/dist/ui/Welcome.js +45 -0
- package/dist/ui/Welcome.js.map +1 -0
- package/dist/ui/theme.d.ts +10 -0
- package/dist/ui/theme.d.ts.map +1 -0
- package/dist/ui/theme.js +9 -0
- package/dist/ui/theme.js.map +1 -0
- package/modules/engram/.gitignore-snippet.txt +6 -0
- package/modules/engram/.mcp-config-snippet.json +11 -0
- package/modules/engram/README.md +146 -0
- package/modules/engram/install-engram.sh +216 -0
- package/modules/ghagga/.env.example +43 -0
- package/modules/ghagga/README.md +153 -0
- package/modules/ghagga/docker-compose.yml +80 -0
- package/modules/ghagga/setup-ghagga.sh +139 -0
- package/modules/memory-simple/.project/NOTES.md +22 -0
- package/modules/memory-simple/README.md +23 -0
- package/modules/obsidian-brain/.obsidian/app.json +23 -0
- package/modules/obsidian-brain/.obsidian/appearance.json +5 -0
- package/modules/obsidian-brain/.obsidian/bookmarks.json +34 -0
- package/modules/obsidian-brain/.obsidian/community-plugins.json +1 -0
- package/modules/obsidian-brain/.obsidian/core-plugins-migration.json +21 -0
- package/modules/obsidian-brain/.obsidian/core-plugins.json +18 -0
- package/modules/obsidian-brain/.obsidian/daily-notes.json +5 -0
- package/modules/obsidian-brain/.obsidian/graph.json +37 -0
- package/modules/obsidian-brain/.obsidian/hotkeys.json +14 -0
- package/modules/obsidian-brain/.obsidian/plugins/dataview/data.json +25 -0
- package/modules/obsidian-brain/.obsidian/plugins/obsidian-kanban/data.json +29 -0
- package/modules/obsidian-brain/.obsidian/plugins/templater-obsidian/data.json +18 -0
- package/modules/obsidian-brain/.obsidian/snippets/project-memory.css +71 -0
- package/modules/obsidian-brain/.obsidian-gitignore-snippet.txt +8 -0
- package/modules/obsidian-brain/.project/Attachments/.gitkeep +0 -0
- package/modules/obsidian-brain/.project/Memory/BLOCKERS.md +78 -0
- package/modules/obsidian-brain/.project/Memory/CONTEXT.md +102 -0
- package/modules/obsidian-brain/.project/Memory/DASHBOARD.md +73 -0
- package/modules/obsidian-brain/.project/Memory/DECISIONS.md +87 -0
- package/modules/obsidian-brain/.project/Memory/KANBAN.md +15 -0
- package/modules/obsidian-brain/.project/Memory/README.md +61 -0
- package/modules/obsidian-brain/.project/Memory/WAVES.md +78 -0
- package/modules/obsidian-brain/.project/Sessions/TEMPLATE.md +99 -0
- package/modules/obsidian-brain/.project/Templates/ADR.md +33 -0
- package/modules/obsidian-brain/.project/Templates/Blocker.md +21 -0
- package/modules/obsidian-brain/.project/Templates/Session.md +88 -0
- package/modules/obsidian-brain/README.md +268 -0
- package/modules/obsidian-brain/new-wave.sh +182 -0
- package/package.json +51 -0
- package/schemas/agent.schema.json +34 -0
- package/schemas/ai-config.schema.json +28 -0
- package/schemas/skill.schema.json +44 -0
- package/src/commands/analyze.test.ts +145 -0
- package/src/commands/analyze.ts +69 -0
- package/src/commands/doctor.test.ts +208 -0
- package/src/commands/doctor.ts +163 -0
- package/src/commands/init.test.ts +298 -0
- package/src/commands/init.ts +285 -0
- package/src/constants.ts +69 -0
- package/src/e2e/aggressive.e2e.test.ts +557 -0
- package/src/e2e/commands.e2e.test.ts +298 -0
- package/src/index.tsx +106 -0
- package/src/lib/common.test.ts +318 -0
- package/src/lib/common.ts +127 -0
- package/src/lib/frontmatter.test.ts +291 -0
- package/src/lib/frontmatter.ts +77 -0
- package/src/lib/template.test.ts +226 -0
- package/src/lib/template.ts +99 -0
- package/src/types/index.ts +53 -0
- package/src/ui/AnalyzeUI.tsx +133 -0
- package/src/ui/App.tsx +175 -0
- package/src/ui/CIContext.tsx +25 -0
- package/src/ui/CISelector.tsx +72 -0
- package/src/ui/Doctor.tsx +122 -0
- package/src/ui/Header.tsx +48 -0
- package/src/ui/MemorySelector.tsx +73 -0
- package/src/ui/NameInput.tsx +82 -0
- package/src/ui/OptionSelector.tsx +100 -0
- package/src/ui/Progress.tsx +88 -0
- package/src/ui/StackSelector.tsx +101 -0
- package/src/ui/Summary.tsx +134 -0
- package/src/ui/Welcome.tsx +54 -0
- package/src/ui/theme.ts +10 -0
- package/stryker.config.json +19 -0
- package/tasks/_TEMPLATE/files-edited.md +3 -0
- package/tasks/_TEMPLATE/plan.md +3 -0
- package/tasks/_TEMPLATE/research.md +3 -0
- package/tasks/_TEMPLATE/verification.md +5 -0
- package/templates/common/dependabot/cargo.yml +11 -0
- package/templates/common/dependabot/github-actions.yml +16 -0
- package/templates/common/dependabot/gomod.yml +15 -0
- package/templates/common/dependabot/gradle.yml +15 -0
- package/templates/common/dependabot/header.yml +3 -0
- package/templates/common/dependabot/maven.yml +15 -0
- package/templates/common/dependabot/npm.yml +20 -0
- package/templates/common/dependabot/pip.yml +11 -0
- package/templates/dependabot.yml +162 -0
- package/templates/github/ci-go.yml +41 -0
- package/templates/github/ci-java.yml +45 -0
- package/templates/github/ci-monorepo.yml +150 -0
- package/templates/github/ci-node.yml +42 -0
- package/templates/github/ci-python.yml +42 -0
- package/templates/github/ci-rust.yml +42 -0
- package/templates/github/dependabot-automerge.yml +40 -0
- package/templates/gitlab/gitlab-ci-go.yml +88 -0
- package/templates/gitlab/gitlab-ci-java.yml +79 -0
- package/templates/gitlab/gitlab-ci-monorepo.yml +126 -0
- package/templates/gitlab/gitlab-ci-node.yml +63 -0
- package/templates/gitlab/gitlab-ci-python.yml +147 -0
- package/templates/gitlab/gitlab-ci-rust.yml +67 -0
- package/templates/global/claude-settings.json +98 -0
- package/templates/global/codex-config.toml +8 -0
- package/templates/global/copilot-instructions/base-rules.instructions.md +13 -0
- package/templates/global/copilot-instructions/sdd-orchestrator.instructions.md +37 -0
- package/templates/global/gemini-commands/cleanup.toml +20 -0
- package/templates/global/gemini-commands/commit.toml +15 -0
- package/templates/global/gemini-commands/dead-code.toml +22 -0
- package/templates/global/gemini-commands/plan.toml +30 -0
- package/templates/global/gemini-commands/review.toml +17 -0
- package/templates/global/gemini-commands/sdd-apply.toml +22 -0
- package/templates/global/gemini-commands/sdd-ff.toml +14 -0
- package/templates/global/gemini-commands/sdd-new.toml +21 -0
- package/templates/global/gemini-commands/sdd-verify.toml +21 -0
- package/templates/global/gemini-commands/tdd.toml +26 -0
- package/templates/global/gemini-settings.json +8 -0
- package/templates/global/opencode-config.json +44 -0
- package/templates/global/sdd-instructions.md +47 -0
- package/templates/global/sdd-orchestrator-claude.md +46 -0
- package/templates/global/sdd-orchestrator-copilot.md +34 -0
- package/templates/renovate.json +69 -0
- package/templates/woodpecker/monorepo/backend.yml +34 -0
- package/templates/woodpecker/monorepo/frontend.yml +34 -0
- package/templates/woodpecker/monorepo/summary.yml +25 -0
- package/templates/woodpecker/woodpecker-go.yml +51 -0
- package/templates/woodpecker/woodpecker-java.yml +67 -0
- package/templates/woodpecker/woodpecker-node.yml +47 -0
- package/templates/woodpecker/woodpecker-python.yml +108 -0
- package/templates/woodpecker/woodpecker-rust.yml +57 -0
- package/tsconfig.json +19 -0
- package/vitest.config.ts +16 -0
- package/workflows/reusable-build-go.yml +111 -0
- package/workflows/reusable-build-java.yml +120 -0
- package/workflows/reusable-build-node.yml +145 -0
- package/workflows/reusable-build-python.yml +159 -0
- package/workflows/reusable-build-rust.yml +135 -0
- package/workflows/reusable-docker.yml +120 -0
- package/workflows/reusable-ghagga-review.yml +165 -0
- package/workflows/reusable-release.yml +91 -0
|
@@ -0,0 +1,1537 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: solo-dev-planner-deployment
|
|
3
|
+
description: "Módulo 4: Deploy con Koyeb, Railway, Coolify"
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# ☁️ Solo Dev Planner - Simple Deployment
|
|
7
|
+
|
|
8
|
+
> Módulo 4 de 6: Deploy económico con Koyeb, Railway, Coolify
|
|
9
|
+
|
|
10
|
+
## 📚 Relacionado con:
|
|
11
|
+
- 01-CORE.md (CI/CD base)
|
|
12
|
+
- 03-PROGRESSIVE-SETUP.md (Fase Beta)
|
|
13
|
+
- 06-OPERATIONS.md (Secrets management)
|
|
14
|
+
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
### Filosofía: PaaS First, AWS Después
|
|
19
|
+
|
|
20
|
+
**Para Solo Devs:**
|
|
21
|
+
```
|
|
22
|
+
❌ AWS:
|
|
23
|
+
- Setup 2-3 horas (IAM, VPC, RDS, Secrets Manager)
|
|
24
|
+
- $50-200/mes
|
|
25
|
+
- Overkill para comenzar
|
|
26
|
+
|
|
27
|
+
✅ Railway/Koyeb/Coolify:
|
|
28
|
+
- Setup 5 minutos
|
|
29
|
+
- git push deploy
|
|
30
|
+
- $0-20/mes
|
|
31
|
+
- Perfecto para solo dev
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
### Comparativa Completa
|
|
35
|
+
|
|
36
|
+
| Plataforma | Precio/mes | Free Tier | Deploy | DB Incluido | Edge Global | Ideal Para |
|
|
37
|
+
|------------|------------|-----------|--------|-------------|-------------|------------|
|
|
38
|
+
| **Koyeb** ⭐ | $0-15 | ✅ 2 servicios | git push | ✅ PostgreSQL | ✅ 6 regiones | MVPs globales, SaaS |
|
|
39
|
+
| **Railway** | $5-20 | $5 crédito | git push | ✅ PostgreSQL | ❌ US only | Simplicidad, hobby |
|
|
40
|
+
| **Coolify** | $5 VPS | ❌ Self-host | git push | ✅ PostgreSQL | Depende | Control total, barato |
|
|
41
|
+
| **Render** | $7-25 | ✅ Limitado | git push | ✅ PostgreSQL | ❌ US/EU | Alternative a Railway |
|
|
42
|
+
| **Fly.io** | $5-20 | ✅ Crédito | fly deploy | ❌ Separado | ✅ Global | Go, Rust, edge apps |
|
|
43
|
+
| AWS (manual) | $30-50+ | ❌ Complejo | CI/CD custom | ❌ RDS manual | ✅ | Apps enterprise |
|
|
44
|
+
|
|
45
|
+
---
|
|
46
|
+
|
|
47
|
+
## 1. Koyeb - Global Edge Deploy (Recomendado) ⭐
|
|
48
|
+
|
|
49
|
+
### ¿Por Qué Koyeb?
|
|
50
|
+
|
|
51
|
+
```
|
|
52
|
+
✅ Free tier GENEROSO (2 servicios, sin tarjeta)
|
|
53
|
+
✅ Global edge (6 regiones: US, EU, Asia)
|
|
54
|
+
✅ Deploy automático desde GitHub
|
|
55
|
+
✅ PostgreSQL integrado (1 click)
|
|
56
|
+
✅ SSL automático + Custom domains
|
|
57
|
+
✅ Zero-downtime deploys
|
|
58
|
+
✅ Auto-scaling
|
|
59
|
+
✅ Logs en tiempo real
|
|
60
|
+
✅ Health checks automáticos
|
|
61
|
+
|
|
62
|
+
Perfecto para:
|
|
63
|
+
- MVPs que quieres lanzar rápido
|
|
64
|
+
- SaaS con usuarios internacionales
|
|
65
|
+
- APIs que necesitan baja latencia global
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
### Setup Koyeb
|
|
69
|
+
|
|
70
|
+
```bash
|
|
71
|
+
# 1. Instalar CLI
|
|
72
|
+
curl -fsSL https://koyeb-cli.s3.amazonaws.com/install.sh | bash
|
|
73
|
+
|
|
74
|
+
# Verificar
|
|
75
|
+
koyeb version
|
|
76
|
+
|
|
77
|
+
# 2. Login
|
|
78
|
+
koyeb login
|
|
79
|
+
|
|
80
|
+
# 3. Deploy desde GitHub (automático)
|
|
81
|
+
koyeb app create my-api \
|
|
82
|
+
--git github.com/user/repo \
|
|
83
|
+
--git-branch main \
|
|
84
|
+
--git-buildCommand "bun install && bun run build" \
|
|
85
|
+
--git-runCommand "bun run start" \
|
|
86
|
+
--ports 8080:http \
|
|
87
|
+
--regions fra,was,sin # Frankfurt, Washington, Singapore
|
|
88
|
+
|
|
89
|
+
# 4. Agregar PostgreSQL
|
|
90
|
+
koyeb database create my-db \
|
|
91
|
+
--engine postgres \
|
|
92
|
+
--version 16
|
|
93
|
+
|
|
94
|
+
# 5. Conectar DB al servicio
|
|
95
|
+
koyeb service update my-api \
|
|
96
|
+
--env DATABASE_URL=@database:my-db:connection_string
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
### Configuración koyeb.yaml
|
|
100
|
+
|
|
101
|
+
```yaml
|
|
102
|
+
# .koyeb.yml - Deploy configuration
|
|
103
|
+
services:
|
|
104
|
+
- name: api
|
|
105
|
+
type: web
|
|
106
|
+
|
|
107
|
+
# Build
|
|
108
|
+
build:
|
|
109
|
+
context: .
|
|
110
|
+
dockerfile: Dockerfile # O usar buildpacks automáticos
|
|
111
|
+
|
|
112
|
+
# Networking
|
|
113
|
+
ports:
|
|
114
|
+
- port: 8080
|
|
115
|
+
protocol: http
|
|
116
|
+
|
|
117
|
+
# Regions (hasta 6 simultáneas)
|
|
118
|
+
regions:
|
|
119
|
+
- fra # Frankfurt, Germany
|
|
120
|
+
- was # Washington DC, USA
|
|
121
|
+
- sin # Singapore
|
|
122
|
+
# - par # Paris, France
|
|
123
|
+
# - sfo # San Francisco, USA
|
|
124
|
+
# - syd # Sydney, Australia
|
|
125
|
+
|
|
126
|
+
# Instance type
|
|
127
|
+
instance:
|
|
128
|
+
type: free # O: nano, small, medium, large
|
|
129
|
+
|
|
130
|
+
# Auto-scaling
|
|
131
|
+
scaling:
|
|
132
|
+
min: 1
|
|
133
|
+
max: 3
|
|
134
|
+
targets:
|
|
135
|
+
- type: cpu
|
|
136
|
+
value: 80 # Scale cuando CPU > 80%
|
|
137
|
+
|
|
138
|
+
# Environment variables
|
|
139
|
+
env:
|
|
140
|
+
- name: NODE_ENV
|
|
141
|
+
value: production
|
|
142
|
+
- name: DATABASE_URL
|
|
143
|
+
secret: DATABASE_URL # From Koyeb secrets
|
|
144
|
+
- name: REDIS_URL
|
|
145
|
+
secret: REDIS_URL
|
|
146
|
+
- name: JWT_SECRET
|
|
147
|
+
secret: JWT_SECRET
|
|
148
|
+
|
|
149
|
+
# Health checks
|
|
150
|
+
health_check:
|
|
151
|
+
http:
|
|
152
|
+
path: /health
|
|
153
|
+
port: 8080
|
|
154
|
+
interval: 30s
|
|
155
|
+
timeout: 10s
|
|
156
|
+
grace_period: 60s
|
|
157
|
+
|
|
158
|
+
# Resources
|
|
159
|
+
resources:
|
|
160
|
+
cpu: 1
|
|
161
|
+
memory: 512Mi
|
|
162
|
+
```
|
|
163
|
+
|
|
164
|
+
### Secrets Management en Koyeb
|
|
165
|
+
|
|
166
|
+
```bash
|
|
167
|
+
# Crear secrets
|
|
168
|
+
koyeb secret create JWT_SECRET --value "your-secret-key-here"
|
|
169
|
+
koyeb secret create DATABASE_URL --value "postgresql://..."
|
|
170
|
+
koyeb secret create STRIPE_SECRET_KEY --value "sk_live_..."
|
|
171
|
+
|
|
172
|
+
# Listar secrets
|
|
173
|
+
koyeb secret list
|
|
174
|
+
|
|
175
|
+
# Actualizar secret
|
|
176
|
+
koyeb secret update JWT_SECRET --value "new-secret"
|
|
177
|
+
|
|
178
|
+
# Usar en servicio (ya configurado en koyeb.yaml)
|
|
179
|
+
env:
|
|
180
|
+
- name: JWT_SECRET
|
|
181
|
+
secret: JWT_SECRET
|
|
182
|
+
```
|
|
183
|
+
|
|
184
|
+
### Mise Tasks para Koyeb
|
|
185
|
+
|
|
186
|
+
```toml
|
|
187
|
+
# .mise.toml
|
|
188
|
+
|
|
189
|
+
[tasks."deploy:setup:koyeb"]
|
|
190
|
+
description = "Setup Koyeb deployment"
|
|
191
|
+
run = """
|
|
192
|
+
#!/usr/bin/env bash
|
|
193
|
+
|
|
194
|
+
echo "🌍 Setting up Koyeb (Global Edge Deploy)..."
|
|
195
|
+
echo ""
|
|
196
|
+
|
|
197
|
+
# Check CLI
|
|
198
|
+
if ! command -v koyeb &> /dev/null; then
|
|
199
|
+
echo "Installing Koyeb CLI..."
|
|
200
|
+
curl -fsSL https://koyeb-cli.s3.amazonaws.com/install.sh | bash
|
|
201
|
+
fi
|
|
202
|
+
|
|
203
|
+
# Login
|
|
204
|
+
echo "Please login to Koyeb:"
|
|
205
|
+
koyeb login
|
|
206
|
+
|
|
207
|
+
# Get project name
|
|
208
|
+
read -p "Project name: " PROJECT_NAME
|
|
209
|
+
read -p "GitHub repo (user/repo): " GITHUB_REPO
|
|
210
|
+
|
|
211
|
+
# Create app
|
|
212
|
+
koyeb app create $PROJECT_NAME \
|
|
213
|
+
--git github.com/$GITHUB_REPO \
|
|
214
|
+
--git-branch main \
|
|
215
|
+
--ports 8080:http \
|
|
216
|
+
--regions fra,was
|
|
217
|
+
|
|
218
|
+
echo ""
|
|
219
|
+
echo "✅ Koyeb configured!"
|
|
220
|
+
echo "Dashboard: https://app.koyeb.com"
|
|
221
|
+
echo ""
|
|
222
|
+
echo "Next steps:"
|
|
223
|
+
echo " 1. Add secrets: koyeb secret create KEY --value VALUE"
|
|
224
|
+
echo " 2. Deploy: git push origin main"
|
|
225
|
+
"""
|
|
226
|
+
|
|
227
|
+
[tasks."deploy:koyeb"]
|
|
228
|
+
description = "Deploy to Koyeb"
|
|
229
|
+
run = """
|
|
230
|
+
echo "🚀 Deploying to Koyeb..."
|
|
231
|
+
koyeb service redeploy $(koyeb service list -o json | jq -r '.[0].id')
|
|
232
|
+
echo "✅ Deployed! Check: https://app.koyeb.com"
|
|
233
|
+
"""
|
|
234
|
+
|
|
235
|
+
[tasks."logs:koyeb"]
|
|
236
|
+
description = "Tail Koyeb logs"
|
|
237
|
+
run = """
|
|
238
|
+
SERVICE_ID=$(koyeb service list -o json | jq -r '.[0].id')
|
|
239
|
+
koyeb service logs $SERVICE_ID --follow
|
|
240
|
+
"""
|
|
241
|
+
|
|
242
|
+
[tasks."status:koyeb"]
|
|
243
|
+
description = "Check Koyeb service status"
|
|
244
|
+
run = "koyeb service list"
|
|
245
|
+
```
|
|
246
|
+
|
|
247
|
+
---
|
|
248
|
+
|
|
249
|
+
## 2. Railway - La Más Simple
|
|
250
|
+
|
|
251
|
+
### ¿Por Qué Railway?
|
|
252
|
+
|
|
253
|
+
```
|
|
254
|
+
✅ UI más intuitiva
|
|
255
|
+
✅ Setup más rápido
|
|
256
|
+
✅ PostgreSQL con 1 click
|
|
257
|
+
✅ Variables de entorno fáciles
|
|
258
|
+
✅ Logs en tiempo real hermosos
|
|
259
|
+
✅ $5 crédito gratis/mes
|
|
260
|
+
✅ Perfect para hobby projects
|
|
261
|
+
|
|
262
|
+
Ideal para:
|
|
263
|
+
- Prototipos rápidos
|
|
264
|
+
- Apps que no necesitan edge global
|
|
265
|
+
- Cuando quieres la máxima simplicidad
|
|
266
|
+
```
|
|
267
|
+
|
|
268
|
+
### Setup Railway
|
|
269
|
+
|
|
270
|
+
```bash
|
|
271
|
+
# 1. Instalar CLI
|
|
272
|
+
npm install -g @railway/cli
|
|
273
|
+
|
|
274
|
+
# O con Homebrew
|
|
275
|
+
brew install railway
|
|
276
|
+
|
|
277
|
+
# 2. Login
|
|
278
|
+
railway login
|
|
279
|
+
|
|
280
|
+
# 3. Inicializar proyecto
|
|
281
|
+
railway init
|
|
282
|
+
|
|
283
|
+
# Seleccionar:
|
|
284
|
+
# - Create new project
|
|
285
|
+
# - Link to GitHub repo (opcional)
|
|
286
|
+
|
|
287
|
+
# 4. Agregar PostgreSQL
|
|
288
|
+
railway add
|
|
289
|
+
# Seleccionar: PostgreSQL
|
|
290
|
+
|
|
291
|
+
# 5. Deploy
|
|
292
|
+
railway up
|
|
293
|
+
|
|
294
|
+
# Railway automáticamente:
|
|
295
|
+
# - Detecta tu lenguaje
|
|
296
|
+
# - Construye la app
|
|
297
|
+
# - Despliega
|
|
298
|
+
# - Genera URL
|
|
299
|
+
```
|
|
300
|
+
|
|
301
|
+
### Configuración railway.json
|
|
302
|
+
|
|
303
|
+
```json
|
|
304
|
+
{
|
|
305
|
+
"$schema": "https://railway.app/railway.schema.json",
|
|
306
|
+
"build": {
|
|
307
|
+
"builder": "DOCKERFILE",
|
|
308
|
+
"dockerfilePath": "./Dockerfile"
|
|
309
|
+
},
|
|
310
|
+
"deploy": {
|
|
311
|
+
"numReplicas": 1,
|
|
312
|
+
"sleepApplication": false,
|
|
313
|
+
"restartPolicyType": "ON_FAILURE",
|
|
314
|
+
"restartPolicyMaxRetries": 10
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
```
|
|
318
|
+
|
|
319
|
+
### Secrets en Railway
|
|
320
|
+
|
|
321
|
+
```bash
|
|
322
|
+
# Via CLI
|
|
323
|
+
railway variables set JWT_SECRET="your-secret"
|
|
324
|
+
railway variables set DATABASE_URL="postgres://..."
|
|
325
|
+
|
|
326
|
+
# Via UI (más fácil)
|
|
327
|
+
# Dashboard > Variables > Add Variable
|
|
328
|
+
```
|
|
329
|
+
|
|
330
|
+
### Mise Tasks para Railway
|
|
331
|
+
|
|
332
|
+
```toml
|
|
333
|
+
[tasks."deploy:setup:railway"]
|
|
334
|
+
description = "Setup Railway deployment"
|
|
335
|
+
run = """
|
|
336
|
+
echo "🚂 Setting up Railway..."
|
|
337
|
+
|
|
338
|
+
if ! command -v railway &> /dev/null; then
|
|
339
|
+
echo "Installing Railway CLI..."
|
|
340
|
+
npm install -g @railway/cli
|
|
341
|
+
fi
|
|
342
|
+
|
|
343
|
+
railway login
|
|
344
|
+
railway init
|
|
345
|
+
|
|
346
|
+
echo ""
|
|
347
|
+
echo "Add PostgreSQL:"
|
|
348
|
+
railway add
|
|
349
|
+
|
|
350
|
+
echo "✅ Railway configured!"
|
|
351
|
+
echo "Deploy: railway up"
|
|
352
|
+
"""
|
|
353
|
+
|
|
354
|
+
[tasks."deploy:railway"]
|
|
355
|
+
description = "Deploy to Railway"
|
|
356
|
+
run = "railway up --detach"
|
|
357
|
+
|
|
358
|
+
[tasks."logs:railway"]
|
|
359
|
+
description = "Tail Railway logs"
|
|
360
|
+
run = "railway logs"
|
|
361
|
+
|
|
362
|
+
[tasks."open:railway"]
|
|
363
|
+
description = "Open Railway dashboard"
|
|
364
|
+
run = "railway open"
|
|
365
|
+
```
|
|
366
|
+
|
|
367
|
+
---
|
|
368
|
+
|
|
369
|
+
## 3. Coolify - Self-Hosted PaaS
|
|
370
|
+
|
|
371
|
+
### ¿Por Qué Coolify?
|
|
372
|
+
|
|
373
|
+
```
|
|
374
|
+
✅ 100% self-hosted (tu servidor)
|
|
375
|
+
✅ Más barato (~$5/mes en Hetzner)
|
|
376
|
+
✅ Control total
|
|
377
|
+
✅ Open source
|
|
378
|
+
✅ UI como Vercel/Railway
|
|
379
|
+
✅ Docker Compose nativo
|
|
380
|
+
✅ Git push deploy
|
|
381
|
+
✅ SSL automático (Let's Encrypt)
|
|
382
|
+
|
|
383
|
+
Ideal para:
|
|
384
|
+
- Quieres controlar todo
|
|
385
|
+
- Presupuesto muy limitado
|
|
386
|
+
- Múltiples proyectos en 1 servidor
|
|
387
|
+
- No quieres vendor lock-in
|
|
388
|
+
```
|
|
389
|
+
|
|
390
|
+
### Setup Coolify en Hetzner
|
|
391
|
+
|
|
392
|
+
```bash
|
|
393
|
+
# ═══════════════════════════════════════════════════════════
|
|
394
|
+
# 1. CREAR VPS EN HETZNER
|
|
395
|
+
# ═══════════════════════════════════════════════════════════
|
|
396
|
+
# Ir a: https://console.hetzner.cloud
|
|
397
|
+
# Crear proyecto
|
|
398
|
+
# Crear servidor:
|
|
399
|
+
# - Location: tu región más cercana
|
|
400
|
+
# - Image: Ubuntu 24.04
|
|
401
|
+
# - Type: CPX11 (2 vCPU, 2 GB RAM, 40 GB SSD) - €4.51/mes
|
|
402
|
+
# - Networking: IPv4 + IPv6
|
|
403
|
+
# - SSH Key: agregar tu clave pública
|
|
404
|
+
|
|
405
|
+
# ═══════════════════════════════════════════════════════════
|
|
406
|
+
# 2. SSH AL SERVIDOR
|
|
407
|
+
# ═══════════════════════════════════════════════════════════
|
|
408
|
+
ssh root@YOUR_SERVER_IP
|
|
409
|
+
|
|
410
|
+
# ═══════════════════════════════════════════════════════════
|
|
411
|
+
# 3. INSTALAR COOLIFY (UN COMANDO)
|
|
412
|
+
# ═══════════════════════════════════════════════════════════
|
|
413
|
+
curl -fsSL https://cdn.coollabs.io/coolify/install.sh | bash
|
|
414
|
+
|
|
415
|
+
# Esto instala:
|
|
416
|
+
# - Docker
|
|
417
|
+
# - Docker Compose
|
|
418
|
+
# - Coolify
|
|
419
|
+
# - Traefik (reverse proxy)
|
|
420
|
+
# - PostgreSQL para Coolify
|
|
421
|
+
|
|
422
|
+
# ═══════════════════════════════════════════════════════════
|
|
423
|
+
# 4. ACCEDER A COOLIFY UI
|
|
424
|
+
# ═══════════════════════════════════════════════════════════
|
|
425
|
+
# Abrir en navegador:
|
|
426
|
+
# http://YOUR_SERVER_IP:8000
|
|
427
|
+
|
|
428
|
+
# Primera vez:
|
|
429
|
+
# - Crear cuenta admin
|
|
430
|
+
# - Configurar dominio (opcional)
|
|
431
|
+
# - Conectar GitHub
|
|
432
|
+
|
|
433
|
+
# ═══════════════════════════════════════════════════════════
|
|
434
|
+
# 5. DESPLEGAR TU APP DESDE UI
|
|
435
|
+
# ═══════════════════════════════════════════════════════════
|
|
436
|
+
# En Coolify UI:
|
|
437
|
+
# 1. New Resource > Application
|
|
438
|
+
# 2. Connect GitHub repo
|
|
439
|
+
# 3. Configure:
|
|
440
|
+
# - Build pack: auto-detect
|
|
441
|
+
# - Port: 8080
|
|
442
|
+
# - Environment variables
|
|
443
|
+
# 4. Deploy
|
|
444
|
+
|
|
445
|
+
# Coolify automáticamente:
|
|
446
|
+
# - Clona el repo
|
|
447
|
+
# - Construye con Dockerfile o buildpacks
|
|
448
|
+
# - Configura reverse proxy
|
|
449
|
+
# - Genera SSL cert
|
|
450
|
+
# - Despliega
|
|
451
|
+
```
|
|
452
|
+
|
|
453
|
+
### docker-compose.yml para Coolify
|
|
454
|
+
|
|
455
|
+
Coolify usa tu `docker-compose.yml` nativo:
|
|
456
|
+
|
|
457
|
+
```yaml
|
|
458
|
+
# docker-compose.yml (Coolify lo usa tal cual)
|
|
459
|
+
version: '3.8'
|
|
460
|
+
|
|
461
|
+
services:
|
|
462
|
+
api:
|
|
463
|
+
build: .
|
|
464
|
+
ports:
|
|
465
|
+
- "8080:8080"
|
|
466
|
+
environment:
|
|
467
|
+
DATABASE_URL: ${DATABASE_URL}
|
|
468
|
+
REDIS_URL: ${REDIS_URL}
|
|
469
|
+
JWT_SECRET: ${JWT_SECRET}
|
|
470
|
+
depends_on:
|
|
471
|
+
- db
|
|
472
|
+
- redis
|
|
473
|
+
restart: unless-stopped
|
|
474
|
+
|
|
475
|
+
db:
|
|
476
|
+
image: postgres:16-alpine
|
|
477
|
+
volumes:
|
|
478
|
+
- postgres_data:/var/lib/postgresql/data
|
|
479
|
+
environment:
|
|
480
|
+
POSTGRES_PASSWORD: ${DB_PASSWORD}
|
|
481
|
+
restart: unless-stopped
|
|
482
|
+
|
|
483
|
+
redis:
|
|
484
|
+
image: redis:7-alpine
|
|
485
|
+
volumes:
|
|
486
|
+
- redis_data:/data
|
|
487
|
+
restart: unless-stopped
|
|
488
|
+
|
|
489
|
+
volumes:
|
|
490
|
+
postgres_data:
|
|
491
|
+
redis_data:
|
|
492
|
+
```
|
|
493
|
+
|
|
494
|
+
### Secrets en Coolify
|
|
495
|
+
|
|
496
|
+
```bash
|
|
497
|
+
# Via UI (más fácil):
|
|
498
|
+
# Project > Environment Variables > Add
|
|
499
|
+
# Checkbox "Secret" para ocultar valor
|
|
500
|
+
|
|
501
|
+
# Variables disponibles automáticamente:
|
|
502
|
+
# - DATABASE_URL (si agregaste PostgreSQL)
|
|
503
|
+
# - Todas las que agregues manualmente
|
|
504
|
+
```
|
|
505
|
+
|
|
506
|
+
### Mise Tasks para Coolify
|
|
507
|
+
|
|
508
|
+
```toml
|
|
509
|
+
[tasks."deploy:setup:coolify"]
|
|
510
|
+
description = "Setup Coolify deployment"
|
|
511
|
+
run = """
|
|
512
|
+
echo "🏠 Setting up Coolify (Self-Hosted)..."
|
|
513
|
+
echo ""
|
|
514
|
+
echo "Steps:"
|
|
515
|
+
echo " 1. Create Hetzner VPS ($5/mes)"
|
|
516
|
+
echo " 2. SSH and run: curl -fsSL https://cdn.coollabs.io/coolify/install.sh | bash"
|
|
517
|
+
echo " 3. Access: http://YOUR_IP:8000"
|
|
518
|
+
echo " 4. Connect GitHub repo"
|
|
519
|
+
echo " 5. Deploy!"
|
|
520
|
+
echo ""
|
|
521
|
+
echo "Docs: https://coolify.io/docs"
|
|
522
|
+
"""
|
|
523
|
+
|
|
524
|
+
[tasks."deploy:coolify"]
|
|
525
|
+
description = "Deploy via git push (Coolify watches repo)"
|
|
526
|
+
run = """
|
|
527
|
+
echo "📤 Pushing to trigger Coolify deploy..."
|
|
528
|
+
git push origin main
|
|
529
|
+
echo "✅ Coolify will auto-deploy"
|
|
530
|
+
echo "Check dashboard: http://YOUR_IP:8000"
|
|
531
|
+
"""
|
|
532
|
+
```
|
|
533
|
+
|
|
534
|
+
---
|
|
535
|
+
|
|
536
|
+
## 4. Mise Tasks Universales para Deployment
|
|
537
|
+
|
|
538
|
+
```toml
|
|
539
|
+
# .mise.toml - Tasks que funcionan con cualquier plataforma
|
|
540
|
+
|
|
541
|
+
[env]
|
|
542
|
+
# Configurar plataforma default
|
|
543
|
+
DEPLOY_PLATFORM = "koyeb" # O: railway, coolify, render
|
|
544
|
+
|
|
545
|
+
[tasks.deploy]
|
|
546
|
+
description = "Deploy to configured platform"
|
|
547
|
+
run = """
|
|
548
|
+
#!/usr/bin/env bash
|
|
549
|
+
|
|
550
|
+
PLATFORM=${DEPLOY_PLATFORM:-koyeb}
|
|
551
|
+
|
|
552
|
+
echo "🚀 Deploying to $PLATFORM..."
|
|
553
|
+
|
|
554
|
+
case $PLATFORM in
|
|
555
|
+
koyeb)
|
|
556
|
+
mise run deploy:koyeb
|
|
557
|
+
;;
|
|
558
|
+
railway)
|
|
559
|
+
mise run deploy:railway
|
|
560
|
+
;;
|
|
561
|
+
coolify)
|
|
562
|
+
echo "Coolify deploys automatically from git push"
|
|
563
|
+
git push origin main
|
|
564
|
+
;;
|
|
565
|
+
render)
|
|
566
|
+
echo "Render deploys automatically from git push"
|
|
567
|
+
git push origin main
|
|
568
|
+
;;
|
|
569
|
+
*)
|
|
570
|
+
echo "❌ Unknown platform: $PLATFORM"
|
|
571
|
+
echo "Set DEPLOY_PLATFORM in .mise.toml to: koyeb, railway, coolify, or render"
|
|
572
|
+
exit 1
|
|
573
|
+
;;
|
|
574
|
+
esac
|
|
575
|
+
"""
|
|
576
|
+
|
|
577
|
+
[tasks.logs]
|
|
578
|
+
description = "Tail production logs"
|
|
579
|
+
run = """
|
|
580
|
+
PLATFORM=${DEPLOY_PLATFORM:-koyeb}
|
|
581
|
+
|
|
582
|
+
case $PLATFORM in
|
|
583
|
+
koyeb)
|
|
584
|
+
mise run logs:koyeb
|
|
585
|
+
;;
|
|
586
|
+
railway)
|
|
587
|
+
mise run logs:railway
|
|
588
|
+
;;
|
|
589
|
+
*)
|
|
590
|
+
echo "Logs command not configured for $PLATFORM"
|
|
591
|
+
;;
|
|
592
|
+
esac
|
|
593
|
+
"""
|
|
594
|
+
|
|
595
|
+
[tasks.status]
|
|
596
|
+
description = "Check deployment status"
|
|
597
|
+
run = """
|
|
598
|
+
PLATFORM=${DEPLOY_PLATFORM:-koyeb}
|
|
599
|
+
|
|
600
|
+
case $PLATFORM in
|
|
601
|
+
koyeb)
|
|
602
|
+
mise run status:koyeb
|
|
603
|
+
;;
|
|
604
|
+
railway)
|
|
605
|
+
railway status
|
|
606
|
+
;;
|
|
607
|
+
*)
|
|
608
|
+
echo "Status command not configured for $PLATFORM"
|
|
609
|
+
;;
|
|
610
|
+
esac
|
|
611
|
+
"""
|
|
612
|
+
|
|
613
|
+
[tasks."deploy:open"]
|
|
614
|
+
description = "Open deployment dashboard"
|
|
615
|
+
run = """
|
|
616
|
+
PLATFORM=${DEPLOY_PLATFORM:-koyeb}
|
|
617
|
+
|
|
618
|
+
case $PLATFORM in
|
|
619
|
+
koyeb)
|
|
620
|
+
open https://app.koyeb.com
|
|
621
|
+
;;
|
|
622
|
+
railway)
|
|
623
|
+
railway open
|
|
624
|
+
;;
|
|
625
|
+
coolify)
|
|
626
|
+
echo "Open: http://YOUR_SERVER_IP:8000"
|
|
627
|
+
;;
|
|
628
|
+
render)
|
|
629
|
+
open https://dashboard.render.com
|
|
630
|
+
;;
|
|
631
|
+
esac
|
|
632
|
+
"""
|
|
633
|
+
```
|
|
634
|
+
|
|
635
|
+
---
|
|
636
|
+
|
|
637
|
+
## 🔐 Secrets Management por Plataforma
|
|
638
|
+
|
|
639
|
+
### Koyeb
|
|
640
|
+
|
|
641
|
+
```bash
|
|
642
|
+
# Crear secret
|
|
643
|
+
koyeb secret create JWT_SECRET --value "your-secret"
|
|
644
|
+
|
|
645
|
+
# En koyeb.yaml
|
|
646
|
+
env:
|
|
647
|
+
- name: JWT_SECRET
|
|
648
|
+
secret: JWT_SECRET
|
|
649
|
+
|
|
650
|
+
# Rotar secret
|
|
651
|
+
koyeb secret update JWT_SECRET --value "new-secret"
|
|
652
|
+
koyeb service redeploy my-api
|
|
653
|
+
```
|
|
654
|
+
|
|
655
|
+
### Railway
|
|
656
|
+
|
|
657
|
+
```bash
|
|
658
|
+
# CLI
|
|
659
|
+
railway variables set JWT_SECRET="your-secret"
|
|
660
|
+
|
|
661
|
+
# UI (recomendado)
|
|
662
|
+
# Dashboard > Variables > New Variable
|
|
663
|
+
# Name: JWT_SECRET
|
|
664
|
+
# Value: your-secret
|
|
665
|
+
```
|
|
666
|
+
|
|
667
|
+
### Coolify
|
|
668
|
+
|
|
669
|
+
```
|
|
670
|
+
# UI únicamente
|
|
671
|
+
# Project > Environment Variables
|
|
672
|
+
# Key: JWT_SECRET
|
|
673
|
+
# Value: your-secret
|
|
674
|
+
# ☑ Secret (hide value)
|
|
675
|
+
```
|
|
676
|
+
|
|
677
|
+
---
|
|
678
|
+
|
|
679
|
+
## 📊 Costos Realistas Comparados
|
|
680
|
+
|
|
681
|
+
### Hobby Project (1,000 req/día)
|
|
682
|
+
|
|
683
|
+
```
|
|
684
|
+
Koyeb: $0/mes (free tier)
|
|
685
|
+
Railway: $5/mes (con crédito incluido)
|
|
686
|
+
Coolify: €5/mes (VPS Hetzner)
|
|
687
|
+
Render: $0/mes (free tier limitado)
|
|
688
|
+
AWS: $30-50/mes (EC2 micro + RDS)
|
|
689
|
+
```
|
|
690
|
+
|
|
691
|
+
### Production (10,000 req/día)
|
|
692
|
+
|
|
693
|
+
```
|
|
694
|
+
Koyeb: $7-15/mes (nano instance + DB)
|
|
695
|
+
Railway: $20-30/mes (starter + DB)
|
|
696
|
+
Coolify: €10/mes (VPS más grande)
|
|
697
|
+
Render: $25-40/mes (starter + DB)
|
|
698
|
+
AWS: $100-200/mes (small EC2 + RDS + varios)
|
|
699
|
+
```
|
|
700
|
+
|
|
701
|
+
### High Traffic (100,000+ req/día)
|
|
702
|
+
|
|
703
|
+
```
|
|
704
|
+
Koyeb: $40-80/mes (medium + scaling)
|
|
705
|
+
Railway: $80-150/mes (pro plan)
|
|
706
|
+
Coolify: €40/mes (multiple VPS)
|
|
707
|
+
Render: $150-300/mes (professional)
|
|
708
|
+
AWS: $500-1000/mes (optimizado)
|
|
709
|
+
```
|
|
710
|
+
|
|
711
|
+
---
|
|
712
|
+
|
|
713
|
+
## 🎯 Recomendación Final por Caso de Uso
|
|
714
|
+
|
|
715
|
+
### Para MVPs y Prototipos
|
|
716
|
+
**→ Koyeb (free tier)**
|
|
717
|
+
- $0/mes
|
|
718
|
+
- Global edge
|
|
719
|
+
- Perfecto para validar idea
|
|
720
|
+
|
|
721
|
+
### Para Hobby Projects
|
|
722
|
+
**→ Railway o Coolify**
|
|
723
|
+
- Railway: Si quieres simplicidad ($5/mes)
|
|
724
|
+
- Coolify: Si quieres ahorrar (€5/mes)
|
|
725
|
+
|
|
726
|
+
### Para SaaS Globales
|
|
727
|
+
**→ Koyeb**
|
|
728
|
+
- Edge deployment
|
|
729
|
+
- Baja latencia mundial
|
|
730
|
+
- Auto-scaling
|
|
731
|
+
|
|
732
|
+
### Para Control Total
|
|
733
|
+
**→ Coolify**
|
|
734
|
+
- Tu servidor, tus reglas
|
|
735
|
+
- Múltiples proyectos
|
|
736
|
+
- Más barato a largo plazo
|
|
737
|
+
|
|
738
|
+
### Para Escalar Después
|
|
739
|
+
**Cualquiera →** Migrar a AWS cuando:
|
|
740
|
+
- > 1M requests/mes
|
|
741
|
+
- Necesitas servicios específicos (Lambda, S3, etc.)
|
|
742
|
+
- Tienes presupuesto para DevOps
|
|
743
|
+
|
|
744
|
+
---
|
|
745
|
+
|
|
746
|
+
## 📝 Changelog y Documentación Automática
|
|
747
|
+
|
|
748
|
+
### Feature Flags con Mise Integrado
|
|
749
|
+
|
|
750
|
+
```yaml
|
|
751
|
+
# .solo-dev/config.yml - Configuración Completa
|
|
752
|
+
features:
|
|
753
|
+
# ═══════════════════════════════════════════════════════════
|
|
754
|
+
# HERRAMIENTAS BASE
|
|
755
|
+
# ═══════════════════════════════════════════════════════════
|
|
756
|
+
mise:
|
|
757
|
+
enabled: true # ✅ Herramienta principal (reemplaza nvm, pyenv, husky, etc.)
|
|
758
|
+
auto_install: true
|
|
759
|
+
version_management: true
|
|
760
|
+
task_runner: true
|
|
761
|
+
git_hooks: true
|
|
762
|
+
|
|
763
|
+
# ═══════════════════════════════════════════════════════════
|
|
764
|
+
# CHANGELOG Y DOCUMENTACIÓN
|
|
765
|
+
# ═══════════════════════════════════════════════════════════
|
|
766
|
+
changelog:
|
|
767
|
+
enabled: true
|
|
768
|
+
mode: 'simple' # 'simple' (Release Please) o 'advanced' (Git Cliff)
|
|
769
|
+
|
|
770
|
+
documentation:
|
|
771
|
+
enabled: true
|
|
772
|
+
mode: 'simple' # 'simple' (manual) o 'advanced' (AI + on-demand)
|
|
773
|
+
ai:
|
|
774
|
+
provider: 'gemini' # 'gemini', 'openai', 'anthropic'
|
|
775
|
+
auto_readme: false
|
|
776
|
+
auto_api_docs: false # on-demand por defecto
|
|
777
|
+
|
|
778
|
+
# ═══════════════════════════════════════════════════════════
|
|
779
|
+
# VALIDACIÓN Y CALIDAD
|
|
780
|
+
# ═══════════════════════════════════════════════════════════
|
|
781
|
+
pre_commit_hooks:
|
|
782
|
+
enabled: true # ✅ Recomendado (via Mise)
|
|
783
|
+
validate_lint: true
|
|
784
|
+
validate_tests: true # Solo tests de archivos modificados
|
|
785
|
+
validate_commit_message: true
|
|
786
|
+
|
|
787
|
+
code_coverage:
|
|
788
|
+
enabled: true # ✅ Recomendado
|
|
789
|
+
provider: 'codecov' # 'codecov' o 'coveralls'
|
|
790
|
+
min_coverage: 80
|
|
791
|
+
fail_under_threshold: false # Solo warning
|
|
792
|
+
|
|
793
|
+
performance_benchmarks:
|
|
794
|
+
enabled: false # Activar si tienes problemas de performance
|
|
795
|
+
fail_on_regression: false
|
|
796
|
+
threshold_percent: 20 # Fallar si regresión >20%
|
|
797
|
+
|
|
798
|
+
# ═══════════════════════════════════════════════════════════
|
|
799
|
+
# SEGURIDAD Y MANTENIMIENTO
|
|
800
|
+
# ═══════════════════════════════════════════════════════════
|
|
801
|
+
dependency_updates:
|
|
802
|
+
enabled: true # ✅ Recomendado (Dependabot)
|
|
803
|
+
schedule: 'weekly' # 'daily', 'weekly', 'monthly'
|
|
804
|
+
auto_merge_patch: false # Auto-merge updates de patch (0.0.X)
|
|
805
|
+
group_updates: true
|
|
806
|
+
|
|
807
|
+
security_scanning:
|
|
808
|
+
enabled: true # ✅ Recomendado
|
|
809
|
+
snyk: false
|
|
810
|
+
github_code_scanning: true
|
|
811
|
+
|
|
812
|
+
# ═══════════════════════════════════════════════════════════
|
|
813
|
+
# DEPLOYMENT Y MONITORING
|
|
814
|
+
# ═══════════════════════════════════════════════════════════
|
|
815
|
+
health_checks:
|
|
816
|
+
enabled: true # ✅ Crítico para auto-merge
|
|
817
|
+
endpoint: '/health'
|
|
818
|
+
timeout_seconds: 30
|
|
819
|
+
retry_count: 3
|
|
820
|
+
|
|
821
|
+
auto_rollback:
|
|
822
|
+
enabled: true # ✅ Crítico - safety net
|
|
823
|
+
on_health_check_fail: true
|
|
824
|
+
on_error_rate_spike: false # Requiere monitoring
|
|
825
|
+
|
|
826
|
+
cloud_cost_estimation:
|
|
827
|
+
enabled: false # ❌ Desactivado por defecto
|
|
828
|
+
provider: 'infracost' # 'infracost' para Terraform/AWS
|
|
829
|
+
fail_above_monthly: 100 # USD
|
|
830
|
+
|
|
831
|
+
# ═══════════════════════════════════════════════════════════
|
|
832
|
+
# NOTIFICACIONES
|
|
833
|
+
# ═══════════════════════════════════════════════════════════
|
|
834
|
+
notifications:
|
|
835
|
+
discord:
|
|
836
|
+
enabled: false # ❌ Desactivado por defecto
|
|
837
|
+
webhook_url_secret: 'DISCORD_WEBHOOK'
|
|
838
|
+
notify_on:
|
|
839
|
+
- 'merge'
|
|
840
|
+
- 'deploy'
|
|
841
|
+
- 'rollback'
|
|
842
|
+
|
|
843
|
+
slack:
|
|
844
|
+
enabled: false
|
|
845
|
+
webhook_url_secret: 'SLACK_WEBHOOK'
|
|
846
|
+
notify_on:
|
|
847
|
+
- 'merge'
|
|
848
|
+
- 'deploy'
|
|
849
|
+
- 'rollback'
|
|
850
|
+
|
|
851
|
+
email:
|
|
852
|
+
enabled: false
|
|
853
|
+
notify_on:
|
|
854
|
+
- 'rollback'
|
|
855
|
+
- 'security_alert'
|
|
856
|
+
|
|
857
|
+
# ═══════════════════════════════════════════════════════════
|
|
858
|
+
# PLANNING Y ORGANIZACIÓN
|
|
859
|
+
# ═══════════════════════════════════════════════════════════
|
|
860
|
+
planning:
|
|
861
|
+
time_estimation: true # ✅ Agregar estimaciones a pasos
|
|
862
|
+
complexity_rating: true # 🟢 Baja, 🟡 Media, 🔴 Alta
|
|
863
|
+
mermaid_diagrams: true # Generar diagramas de arquitectura
|
|
864
|
+
github_issues: true # Crear issues por cada paso
|
|
865
|
+
```
|
|
866
|
+
|
|
867
|
+
---
|
|
868
|
+
|
|
869
|
+
## 🚀 Mise: Herramienta Universal (Version Manager + Task Runner + Hooks)
|
|
870
|
+
|
|
871
|
+
### ¿Por qué Mise?
|
|
872
|
+
|
|
873
|
+
```
|
|
874
|
+
❌ Antes (múltiples herramientas):
|
|
875
|
+
- nvm (Node versions)
|
|
876
|
+
- pyenv (Python versions)
|
|
877
|
+
- gvm (Go versions)
|
|
878
|
+
- jenv (Java versions)
|
|
879
|
+
- Husky (Git hooks, solo Node)
|
|
880
|
+
- Make/Just (Task runner)
|
|
881
|
+
- dotenv (Env management)
|
|
882
|
+
|
|
883
|
+
✅ Con Mise (una sola herramienta):
|
|
884
|
+
- ✅ Version management (todos los lenguajes)
|
|
885
|
+
- ✅ Task runner (scripts universales)
|
|
886
|
+
- ✅ Git hooks (cualquier lenguaje)
|
|
887
|
+
- ✅ Env management (.env nativo)
|
|
888
|
+
- ✅ Auto-activation (al entrar al dir)
|
|
889
|
+
- ✅ Escrito en Rust (ultra rápido)
|
|
890
|
+
```
|
|
891
|
+
|
|
892
|
+
### Instalación
|
|
893
|
+
|
|
894
|
+
```bash
|
|
895
|
+
# ═══════════════════════════════════════════════════════════
|
|
896
|
+
# INSTALACIÓN
|
|
897
|
+
# ═══════════════════════════════════════════════════════════
|
|
898
|
+
|
|
899
|
+
# Homebrew (macOS/Linux) - RECOMENDADO
|
|
900
|
+
brew install mise
|
|
901
|
+
|
|
902
|
+
# Script oficial (Linux/macOS)
|
|
903
|
+
curl https://mise.run | sh
|
|
904
|
+
|
|
905
|
+
# Cargo (Rust)
|
|
906
|
+
cargo install mise
|
|
907
|
+
|
|
908
|
+
# apt (Ubuntu/Debian)
|
|
909
|
+
apt update && apt install -y mise
|
|
910
|
+
|
|
911
|
+
# Verificar instalación
|
|
912
|
+
mise --version
|
|
913
|
+
```
|
|
914
|
+
|
|
915
|
+
### Activación en Shell
|
|
916
|
+
|
|
917
|
+
```bash
|
|
918
|
+
# ═══════════════════════════════════════════════════════════
|
|
919
|
+
# ACTIVAR EN TU SHELL (IMPORTANTE)
|
|
920
|
+
# ═══════════════════════════════════════════════════════════
|
|
921
|
+
|
|
922
|
+
# Zsh (macOS default)
|
|
923
|
+
echo 'eval "$(mise activate zsh)"' >> ~/.zshrc
|
|
924
|
+
source ~/.zshrc
|
|
925
|
+
|
|
926
|
+
# Bash
|
|
927
|
+
echo 'eval "$(mise activate bash)"' >> ~/.bashrc
|
|
928
|
+
source ~/.bashrc
|
|
929
|
+
|
|
930
|
+
# Fish
|
|
931
|
+
echo 'mise activate fish | source' >> ~/.config/fish/config.fish
|
|
932
|
+
|
|
933
|
+
# Verificar
|
|
934
|
+
cd /tmp && mkdir test-mise && cd test-mise
|
|
935
|
+
mise use node@20
|
|
936
|
+
node --version # Debería mostrar v20.x
|
|
937
|
+
```
|
|
938
|
+
|
|
939
|
+
---
|
|
940
|
+
|
|
941
|
+
## 📋 Configuración Universal (.mise.toml)
|
|
942
|
+
|
|
943
|
+
### Template Completo para Solo-Dev-Planner
|
|
944
|
+
|
|
945
|
+
```toml
|
|
946
|
+
# .mise.toml - Configuración universal para cualquier lenguaje
|
|
947
|
+
# Este archivo define: versiones, tareas, hooks, y variables de entorno
|
|
948
|
+
|
|
949
|
+
min_version = "2024.1.0"
|
|
950
|
+
|
|
951
|
+
# ═══════════════════════════════════════════════════════════
|
|
952
|
+
# VERSION MANAGEMENT (auto-detecta y activa al entrar al dir)
|
|
953
|
+
# ═══════════════════════════════════════════════════════════
|
|
954
|
+
[tools]
|
|
955
|
+
# Solo incluye los lenguajes que uses en tu proyecto
|
|
956
|
+
# Mise auto-detecta cuáles están presentes
|
|
957
|
+
|
|
958
|
+
# JavaScript/TypeScript
|
|
959
|
+
node = "20.11.0" # LTS, reemplaza nvm
|
|
960
|
+
bun = "1.0.25" # Runtime moderno
|
|
961
|
+
|
|
962
|
+
# Python
|
|
963
|
+
python = "3.12.1" # Reemplaza pyenv
|
|
964
|
+
uv = "latest" # Package manager
|
|
965
|
+
|
|
966
|
+
# Go
|
|
967
|
+
go = "1.22.0" # Reemplaza gvm
|
|
968
|
+
|
|
969
|
+
# Java/Kotlin
|
|
970
|
+
java = "temurin-21" # Reemplaza jenv/sdkman
|
|
971
|
+
|
|
972
|
+
# Rust
|
|
973
|
+
rust = "stable" # Reemplaza rustup
|
|
974
|
+
|
|
975
|
+
# Herramientas adicionales (opcionales)
|
|
976
|
+
terraform = "1.7.0"
|
|
977
|
+
kubectl = "1.29.0"
|
|
978
|
+
helm = "3.14.0"
|
|
979
|
+
|
|
980
|
+
# También puedes usar ranges:
|
|
981
|
+
# node = "20" # Latest 20.x
|
|
982
|
+
# python = ">=3.11" # Cualquier 3.11+
|
|
983
|
+
# go = "latest" # Última versión
|
|
984
|
+
|
|
985
|
+
# ═══════════════════════════════════════════════════════════
|
|
986
|
+
# ENVIRONMENT VARIABLES
|
|
987
|
+
# ═══════════════════════════════════════════════════════════
|
|
988
|
+
[env]
|
|
989
|
+
# Variables del proyecto
|
|
990
|
+
NODE_ENV = "development"
|
|
991
|
+
LOG_LEVEL = "debug"
|
|
992
|
+
PORT = "8080"
|
|
993
|
+
|
|
994
|
+
# Database
|
|
995
|
+
DATABASE_URL = "postgresql://localhost:5432/mydb"
|
|
996
|
+
REDIS_URL = "redis://localhost:6379"
|
|
997
|
+
|
|
998
|
+
# Paths
|
|
999
|
+
_.path = ["./bin", "./node_modules/.bin", "$PATH"]
|
|
1000
|
+
|
|
1001
|
+
# Cargar desde archivos
|
|
1002
|
+
_.file = [".env", ".env.local"]
|
|
1003
|
+
|
|
1004
|
+
# Por environment
|
|
1005
|
+
[env.production]
|
|
1006
|
+
NODE_ENV = "production"
|
|
1007
|
+
LOG_LEVEL = "info"
|
|
1008
|
+
|
|
1009
|
+
# ═══════════════════════════════════════════════════════════
|
|
1010
|
+
# TASK RUNNER (scripts universales multi-lenguaje)
|
|
1011
|
+
# ═══════════════════════════════════════════════════════════
|
|
1012
|
+
|
|
1013
|
+
[tasks.dev]
|
|
1014
|
+
description = "Start development server"
|
|
1015
|
+
run = """
|
|
1016
|
+
#!/usr/bin/env bash
|
|
1017
|
+
set -e
|
|
1018
|
+
|
|
1019
|
+
echo "🚀 Starting development server..."
|
|
1020
|
+
|
|
1021
|
+
if [ -f "package.json" ]; then
|
|
1022
|
+
echo "📦 Detected Node/Bun project"
|
|
1023
|
+
if command -v bun &> /dev/null; then
|
|
1024
|
+
bun run dev
|
|
1025
|
+
else
|
|
1026
|
+
npm run dev
|
|
1027
|
+
fi
|
|
1028
|
+
elif [ -f "pyproject.toml" ]; then
|
|
1029
|
+
echo "🐍 Detected Python project"
|
|
1030
|
+
if command -v uv &> /dev/null; then
|
|
1031
|
+
uv run fastapi dev app/main.py
|
|
1032
|
+
else
|
|
1033
|
+
python -m uvicorn app.main:app --reload
|
|
1034
|
+
fi
|
|
1035
|
+
elif [ -f "go.mod" ]; then
|
|
1036
|
+
echo "🐹 Detected Go project"
|
|
1037
|
+
if command -v air &> /dev/null; then
|
|
1038
|
+
air
|
|
1039
|
+
else
|
|
1040
|
+
go run cmd/api/main.go
|
|
1041
|
+
fi
|
|
1042
|
+
elif [ -f "build.gradle.kts" ]; then
|
|
1043
|
+
echo "☕ Detected Java/Kotlin project"
|
|
1044
|
+
./gradlew bootRun
|
|
1045
|
+
elif [ -f "Cargo.toml" ]; then
|
|
1046
|
+
echo "🦀 Detected Rust project"
|
|
1047
|
+
cargo watch -x run
|
|
1048
|
+
else
|
|
1049
|
+
echo "❌ Could not detect project type"
|
|
1050
|
+
exit 1
|
|
1051
|
+
fi
|
|
1052
|
+
"""
|
|
1053
|
+
alias = "d"
|
|
1054
|
+
|
|
1055
|
+
[tasks.test]
|
|
1056
|
+
description = "Run tests"
|
|
1057
|
+
run = """
|
|
1058
|
+
#!/usr/bin/env bash
|
|
1059
|
+
set -e
|
|
1060
|
+
|
|
1061
|
+
echo "🧪 Running tests..."
|
|
1062
|
+
|
|
1063
|
+
if [ -f "package.json" ]; then
|
|
1064
|
+
if command -v bun &> /dev/null; then
|
|
1065
|
+
bun test
|
|
1066
|
+
else
|
|
1067
|
+
npm test
|
|
1068
|
+
fi
|
|
1069
|
+
elif [ -f "pyproject.toml" ]; then
|
|
1070
|
+
if command -v uv &> /dev/null; then
|
|
1071
|
+
uv run pytest
|
|
1072
|
+
else
|
|
1073
|
+
pytest
|
|
1074
|
+
fi
|
|
1075
|
+
elif [ -f "go.mod" ]; then
|
|
1076
|
+
go test ./...
|
|
1077
|
+
elif [ -f "build.gradle.kts" ]; then
|
|
1078
|
+
./gradlew test
|
|
1079
|
+
elif [ -f "Cargo.toml" ]; then
|
|
1080
|
+
cargo test
|
|
1081
|
+
fi
|
|
1082
|
+
"""
|
|
1083
|
+
alias = "t"
|
|
1084
|
+
|
|
1085
|
+
[tasks."test:changed"]
|
|
1086
|
+
description = "Run tests only for changed files"
|
|
1087
|
+
run = "./scripts/test-changed.sh"
|
|
1088
|
+
|
|
1089
|
+
[tasks.lint]
|
|
1090
|
+
description = "Lint code"
|
|
1091
|
+
run = """
|
|
1092
|
+
#!/usr/bin/env bash
|
|
1093
|
+
set -e
|
|
1094
|
+
|
|
1095
|
+
echo "🔍 Linting code..."
|
|
1096
|
+
|
|
1097
|
+
if [ -f "biome.json" ]; then
|
|
1098
|
+
echo "Using Biome..."
|
|
1099
|
+
bunx @biomejs/biome check .
|
|
1100
|
+
elif [ -f ".golangci.yml" ]; then
|
|
1101
|
+
echo "Using golangci-lint..."
|
|
1102
|
+
golangci-lint run
|
|
1103
|
+
elif [ -f "pyproject.toml" ] && grep -q "ruff" pyproject.toml; then
|
|
1104
|
+
echo "Using Ruff..."
|
|
1105
|
+
ruff check .
|
|
1106
|
+
elif [ -f "build.gradle.kts" ]; then
|
|
1107
|
+
echo "Using Spotless..."
|
|
1108
|
+
./gradlew spotlessCheck
|
|
1109
|
+
elif [ -f "Cargo.toml" ]; then
|
|
1110
|
+
echo "Using Clippy..."
|
|
1111
|
+
cargo clippy
|
|
1112
|
+
fi
|
|
1113
|
+
"""
|
|
1114
|
+
alias = "l"
|
|
1115
|
+
|
|
1116
|
+
[tasks.format]
|
|
1117
|
+
description = "Format code"
|
|
1118
|
+
run = """
|
|
1119
|
+
#!/usr/bin/env bash
|
|
1120
|
+
set -e
|
|
1121
|
+
|
|
1122
|
+
echo "🎨 Formatting code..."
|
|
1123
|
+
|
|
1124
|
+
if [ -f "biome.json" ]; then
|
|
1125
|
+
bunx @biomejs/biome format --write .
|
|
1126
|
+
elif [ -f "go.mod" ]; then
|
|
1127
|
+
gofmt -w .
|
|
1128
|
+
goimports -w .
|
|
1129
|
+
elif [ -f "pyproject.toml" ] && grep -q "ruff" pyproject.toml; then
|
|
1130
|
+
ruff format .
|
|
1131
|
+
elif [ -f "build.gradle.kts" ]; then
|
|
1132
|
+
./gradlew spotlessApply
|
|
1133
|
+
elif [ -f "Cargo.toml" ]; then
|
|
1134
|
+
cargo fmt
|
|
1135
|
+
fi
|
|
1136
|
+
"""
|
|
1137
|
+
alias = "f"
|
|
1138
|
+
|
|
1139
|
+
[tasks.build]
|
|
1140
|
+
description = "Build for production"
|
|
1141
|
+
run = """
|
|
1142
|
+
#!/usr/bin/env bash
|
|
1143
|
+
set -e
|
|
1144
|
+
|
|
1145
|
+
echo "🏗️ Building for production..."
|
|
1146
|
+
|
|
1147
|
+
if [ -f "package.json" ]; then
|
|
1148
|
+
if command -v bun &> /dev/null; then
|
|
1149
|
+
bun run build
|
|
1150
|
+
else
|
|
1151
|
+
npm run build
|
|
1152
|
+
fi
|
|
1153
|
+
elif [ -f "pyproject.toml" ]; then
|
|
1154
|
+
echo "Python projects typically don't need building"
|
|
1155
|
+
elif [ -f "go.mod" ]; then
|
|
1156
|
+
go build -o bin/app cmd/api/main.go
|
|
1157
|
+
elif [ -f "build.gradle.kts" ]; then
|
|
1158
|
+
./gradlew build
|
|
1159
|
+
elif [ -f "Cargo.toml" ]; then
|
|
1160
|
+
cargo build --release
|
|
1161
|
+
fi
|
|
1162
|
+
"""
|
|
1163
|
+
alias = "b"
|
|
1164
|
+
depends = ["lint", "test"] # Corre lint y test primero
|
|
1165
|
+
|
|
1166
|
+
[tasks."db:start"]
|
|
1167
|
+
description = "Start database containers"
|
|
1168
|
+
run = "docker compose up -d db redis"
|
|
1169
|
+
|
|
1170
|
+
[tasks."db:migrate"]
|
|
1171
|
+
description = "Run database migrations"
|
|
1172
|
+
run = """
|
|
1173
|
+
#!/usr/bin/env bash
|
|
1174
|
+
if [ -f "go.mod" ]; then
|
|
1175
|
+
migrate -path migrations -database "$DATABASE_URL" up
|
|
1176
|
+
elif [ -f "pyproject.toml" ]; then
|
|
1177
|
+
alembic upgrade head
|
|
1178
|
+
fi
|
|
1179
|
+
"""
|
|
1180
|
+
depends = ["db:start"]
|
|
1181
|
+
|
|
1182
|
+
[tasks."db:seed"]
|
|
1183
|
+
description = "Seed database with test data"
|
|
1184
|
+
run = "./scripts/seed.sh"
|
|
1185
|
+
depends = ["db:migrate"]
|
|
1186
|
+
|
|
1187
|
+
[tasks.clean]
|
|
1188
|
+
description = "Clean build artifacts"
|
|
1189
|
+
run = """
|
|
1190
|
+
#!/usr/bin/env bash
|
|
1191
|
+
rm -rf dist/ build/ target/ node_modules/.cache
|
|
1192
|
+
echo "✨ Cleaned build artifacts"
|
|
1193
|
+
"""
|
|
1194
|
+
|
|
1195
|
+
[tasks.install]
|
|
1196
|
+
description = "Install dependencies"
|
|
1197
|
+
run = """
|
|
1198
|
+
#!/usr/bin/env bash
|
|
1199
|
+
set -e
|
|
1200
|
+
|
|
1201
|
+
echo "📦 Installing dependencies..."
|
|
1202
|
+
|
|
1203
|
+
if [ -f "package.json" ]; then
|
|
1204
|
+
if command -v bun &> /dev/null; then
|
|
1205
|
+
bun install
|
|
1206
|
+
else
|
|
1207
|
+
npm install
|
|
1208
|
+
fi
|
|
1209
|
+
elif [ -f "pyproject.toml" ]; then
|
|
1210
|
+
if command -v uv &> /dev/null; then
|
|
1211
|
+
uv sync
|
|
1212
|
+
else
|
|
1213
|
+
pip install -e .
|
|
1214
|
+
fi
|
|
1215
|
+
elif [ -f "go.mod" ]; then
|
|
1216
|
+
go mod download
|
|
1217
|
+
elif [ -f "build.gradle.kts" ]; then
|
|
1218
|
+
./gradlew build --refresh-dependencies
|
|
1219
|
+
elif [ -f "Cargo.toml" ]; then
|
|
1220
|
+
cargo fetch
|
|
1221
|
+
fi
|
|
1222
|
+
|
|
1223
|
+
echo "✅ Dependencies installed"
|
|
1224
|
+
"""
|
|
1225
|
+
|
|
1226
|
+
[tasks.ci]
|
|
1227
|
+
description = "Run full CI pipeline locally"
|
|
1228
|
+
run = "mise run lint && mise run test && mise run build"
|
|
1229
|
+
|
|
1230
|
+
# ═══════════════════════════════════════════════════════════
|
|
1231
|
+
# GIT HOOKS (con feature flags)
|
|
1232
|
+
# ═══════════════════════════════════════════════════════════
|
|
1233
|
+
|
|
1234
|
+
[hooks.pre-commit]
|
|
1235
|
+
run = """
|
|
1236
|
+
#!/usr/bin/env bash
|
|
1237
|
+
set -e
|
|
1238
|
+
|
|
1239
|
+
echo "🎣 Running pre-commit hooks..."
|
|
1240
|
+
|
|
1241
|
+
# Leer feature flags de config
|
|
1242
|
+
CONFIG_FILE=".solo-dev/config.yml"
|
|
1243
|
+
LINT_ENABLED="true"
|
|
1244
|
+
TEST_ENABLED="true"
|
|
1245
|
+
|
|
1246
|
+
if [ -f "$CONFIG_FILE" ]; then
|
|
1247
|
+
if command -v yq &> /dev/null; then
|
|
1248
|
+
LINT_ENABLED=$(yq eval '.features.pre_commit_hooks.validate_lint' "$CONFIG_FILE" 2>/dev/null || echo "true")
|
|
1249
|
+
TEST_ENABLED=$(yq eval '.features.pre_commit_hooks.validate_tests' "$CONFIG_FILE" 2>/dev/null || echo "true")
|
|
1250
|
+
fi
|
|
1251
|
+
fi
|
|
1252
|
+
|
|
1253
|
+
# Lint (si está habilitado)
|
|
1254
|
+
if [ "$LINT_ENABLED" = "true" ]; then
|
|
1255
|
+
echo "🎨 Running linter..."
|
|
1256
|
+
mise run lint || {
|
|
1257
|
+
echo "❌ Lint failed. Run 'mise run format' to auto-fix."
|
|
1258
|
+
exit 1
|
|
1259
|
+
}
|
|
1260
|
+
fi
|
|
1261
|
+
|
|
1262
|
+
# Tests (solo archivos cambiados, si está habilitado)
|
|
1263
|
+
if [ "$TEST_ENABLED" = "true" ]; then
|
|
1264
|
+
echo "🧪 Running tests on changed files..."
|
|
1265
|
+
mise run test:changed || {
|
|
1266
|
+
echo "❌ Tests failed. Fix and try again."
|
|
1267
|
+
exit 1
|
|
1268
|
+
}
|
|
1269
|
+
fi
|
|
1270
|
+
|
|
1271
|
+
echo "✅ Pre-commit checks passed!"
|
|
1272
|
+
"""
|
|
1273
|
+
|
|
1274
|
+
[hooks.commit-msg]
|
|
1275
|
+
run = """
|
|
1276
|
+
#!/usr/bin/env bash
|
|
1277
|
+
|
|
1278
|
+
# Leer feature flags
|
|
1279
|
+
CONFIG_FILE=".solo-dev/config.yml"
|
|
1280
|
+
VALIDATE_ENABLED="true"
|
|
1281
|
+
|
|
1282
|
+
if [ -f "$CONFIG_FILE" ]; then
|
|
1283
|
+
if command -v yq &> /dev/null; then
|
|
1284
|
+
VALIDATE_ENABLED=$(yq eval '.features.pre_commit_hooks.validate_commit_message' "$CONFIG_FILE" 2>/dev/null || echo "true")
|
|
1285
|
+
fi
|
|
1286
|
+
fi
|
|
1287
|
+
|
|
1288
|
+
if [ "$VALIDATE_ENABLED" != "true" ]; then
|
|
1289
|
+
exit 0
|
|
1290
|
+
fi
|
|
1291
|
+
|
|
1292
|
+
# Validar formato Conventional Commits
|
|
1293
|
+
msg=$(cat "$1")
|
|
1294
|
+
|
|
1295
|
+
if ! echo "$msg" | grep -qE '^(feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert)(\(.+\))?: .+'; then
|
|
1296
|
+
echo "❌ Invalid commit message format"
|
|
1297
|
+
echo ""
|
|
1298
|
+
echo "Commit message must follow Conventional Commits:"
|
|
1299
|
+
echo " feat(scope): add new feature"
|
|
1300
|
+
echo " fix(scope): fix bug"
|
|
1301
|
+
echo " docs: update documentation"
|
|
1302
|
+
echo ""
|
|
1303
|
+
echo "Types: feat, fix, docs, style, refactor, perf, test, chore"
|
|
1304
|
+
exit 1
|
|
1305
|
+
fi
|
|
1306
|
+
|
|
1307
|
+
# Verificar longitud del subject
|
|
1308
|
+
subject=$(echo "$msg" | head -1)
|
|
1309
|
+
if [ ${#subject} -gt 72 ]; then
|
|
1310
|
+
echo "❌ Subject line too long (max 72 characters)"
|
|
1311
|
+
exit 1
|
|
1312
|
+
fi
|
|
1313
|
+
|
|
1314
|
+
echo "✅ Commit message validated"
|
|
1315
|
+
"""
|
|
1316
|
+
|
|
1317
|
+
[hooks.pre-push]
|
|
1318
|
+
run = """
|
|
1319
|
+
#!/usr/bin/env bash
|
|
1320
|
+
set -e
|
|
1321
|
+
|
|
1322
|
+
echo "🚀 Running pre-push hooks..."
|
|
1323
|
+
|
|
1324
|
+
# Correr suite completa de tests
|
|
1325
|
+
echo "🧪 Running full test suite..."
|
|
1326
|
+
mise run test
|
|
1327
|
+
|
|
1328
|
+
# Build
|
|
1329
|
+
echo "🏗️ Building project..."
|
|
1330
|
+
mise run build
|
|
1331
|
+
|
|
1332
|
+
echo "✅ Pre-push checks passed!"
|
|
1333
|
+
"""
|
|
1334
|
+
|
|
1335
|
+
# ═══════════════════════════════════════════════════════════
|
|
1336
|
+
# SETTINGS
|
|
1337
|
+
# ═══════════════════════════════════════════════════════════
|
|
1338
|
+
[settings]
|
|
1339
|
+
experimental = true
|
|
1340
|
+
legacy_version_file = true # Soporta .nvmrc, .python-version, etc.
|
|
1341
|
+
```
|
|
1342
|
+
|
|
1343
|
+
---
|
|
1344
|
+
|
|
1345
|
+
## 🎯 Uso Diario con Mise
|
|
1346
|
+
|
|
1347
|
+
### Setup Inicial del Proyecto
|
|
1348
|
+
|
|
1349
|
+
```bash
|
|
1350
|
+
# 1. Entrar al proyecto
|
|
1351
|
+
cd mi-proyecto
|
|
1352
|
+
|
|
1353
|
+
# 2. Definir versiones (crea .mise.toml automáticamente)
|
|
1354
|
+
mise use node@20 python@3.12 go@1.22
|
|
1355
|
+
|
|
1356
|
+
# 3. Instalar todas las versiones
|
|
1357
|
+
mise install
|
|
1358
|
+
|
|
1359
|
+
# 4. Instalar dependencias del proyecto
|
|
1360
|
+
mise run install
|
|
1361
|
+
|
|
1362
|
+
# 5. Setup git hooks
|
|
1363
|
+
mise hook-env
|
|
1364
|
+
|
|
1365
|
+
# 6. Verificar que todo funciona
|
|
1366
|
+
mise doctor
|
|
1367
|
+
mise current
|
|
1368
|
+
|
|
1369
|
+
# 7. Listo! 🎉
|
|
1370
|
+
mise run dev
|
|
1371
|
+
```
|
|
1372
|
+
|
|
1373
|
+
### Comandos del Día a Día
|
|
1374
|
+
|
|
1375
|
+
```bash
|
|
1376
|
+
# ═══════════════════════════════════════════════════════════
|
|
1377
|
+
# VERSION MANAGEMENT
|
|
1378
|
+
# ═══════════════════════════════════════════════════════════
|
|
1379
|
+
|
|
1380
|
+
# Ver versiones activas
|
|
1381
|
+
mise current
|
|
1382
|
+
|
|
1383
|
+
# Listar versiones disponibles
|
|
1384
|
+
mise ls-remote node
|
|
1385
|
+
mise ls-remote python
|
|
1386
|
+
|
|
1387
|
+
# Instalar versión específica
|
|
1388
|
+
mise install node@21.5.0
|
|
1389
|
+
|
|
1390
|
+
# Usar versión globalmente (en todos los proyectos)
|
|
1391
|
+
mise use -g node@20
|
|
1392
|
+
|
|
1393
|
+
# Ver todas las herramientas instaladas
|
|
1394
|
+
mise list
|
|
1395
|
+
|
|
1396
|
+
# Actualizar herramientas
|
|
1397
|
+
mise upgrade
|
|
1398
|
+
|
|
1399
|
+
# ═══════════════════════════════════════════════════════════
|
|
1400
|
+
# TASK RUNNER
|
|
1401
|
+
# ═══════════════════════════════════════════════════════════
|
|
1402
|
+
|
|
1403
|
+
# Correr tareas
|
|
1404
|
+
mise run dev # Start dev server
|
|
1405
|
+
mise run test # Run tests
|
|
1406
|
+
mise run lint # Lint code
|
|
1407
|
+
mise run format # Format code
|
|
1408
|
+
mise run build # Build for production
|
|
1409
|
+
|
|
1410
|
+
# Ver tareas disponibles
|
|
1411
|
+
mise tasks
|
|
1412
|
+
|
|
1413
|
+
# Usar aliases (más corto)
|
|
1414
|
+
mise x d # = mise run dev
|
|
1415
|
+
mise x t # = mise run test
|
|
1416
|
+
mise x l # = mise run lint
|
|
1417
|
+
|
|
1418
|
+
# Correr múltiples tareas
|
|
1419
|
+
mise run lint test build
|
|
1420
|
+
|
|
1421
|
+
# Correr en background
|
|
1422
|
+
mise run dev &
|
|
1423
|
+
|
|
1424
|
+
# ═══════════════════════════════════════════════════════════
|
|
1425
|
+
# ENVIRONMENT MANAGEMENT
|
|
1426
|
+
# ═══════════════════════════════════════════════════════════
|
|
1427
|
+
|
|
1428
|
+
# Ver variables de entorno
|
|
1429
|
+
mise env
|
|
1430
|
+
|
|
1431
|
+
# Exportar env vars al shell actual
|
|
1432
|
+
eval "$(mise env)"
|
|
1433
|
+
|
|
1434
|
+
# Ver variable específica
|
|
1435
|
+
mise env | grep DATABASE_URL
|
|
1436
|
+
|
|
1437
|
+
# Correr comando con env
|
|
1438
|
+
mise exec -- printenv DATABASE_URL
|
|
1439
|
+
|
|
1440
|
+
# Cambiar environment
|
|
1441
|
+
mise env --profile production
|
|
1442
|
+
|
|
1443
|
+
# ═══════════════════════════════════════════════════════════
|
|
1444
|
+
# GIT HOOKS
|
|
1445
|
+
# ═══════════════════════════════════════════════════════════
|
|
1446
|
+
|
|
1447
|
+
# Hooks se activan automáticamente
|
|
1448
|
+
git commit -m "feat: nueva feature"
|
|
1449
|
+
# → pre-commit hook corre automáticamente
|
|
1450
|
+
|
|
1451
|
+
git push
|
|
1452
|
+
# → pre-push hook corre automáticamente
|
|
1453
|
+
|
|
1454
|
+
# Skip hooks si es necesario
|
|
1455
|
+
MISE_SKIP_HOOKS=1 git commit -m "feat: skip hooks"
|
|
1456
|
+
# O
|
|
1457
|
+
git commit -m "feat: skip" --no-verify
|
|
1458
|
+
|
|
1459
|
+
# ═══════════════════════════════════════════════════════════
|
|
1460
|
+
# DEBUGGING
|
|
1461
|
+
# ═══════════════════════════════════════════════════════════
|
|
1462
|
+
|
|
1463
|
+
# Ver qué está haciendo Mise
|
|
1464
|
+
mise doctor
|
|
1465
|
+
|
|
1466
|
+
# Ver logs detallados
|
|
1467
|
+
MISE_DEBUG=1 mise run dev
|
|
1468
|
+
|
|
1469
|
+
# Ver qué hooks están activos
|
|
1470
|
+
mise hook-env --status
|
|
1471
|
+
|
|
1472
|
+
# Limpiar cache
|
|
1473
|
+
mise cache clear
|
|
1474
|
+
```
|
|
1475
|
+
|
|
1476
|
+
### Auto-activation (Magia ✨)
|
|
1477
|
+
|
|
1478
|
+
```bash
|
|
1479
|
+
# Cuando entras a un directorio con .mise.toml,
|
|
1480
|
+
# Mise activa automáticamente las versiones correctas
|
|
1481
|
+
|
|
1482
|
+
cd ~/proyectos/api-node
|
|
1483
|
+
# → Node 20, Bun latest activados ✨
|
|
1484
|
+
node --version # v20.11.0
|
|
1485
|
+
|
|
1486
|
+
cd ~/proyectos/api-python
|
|
1487
|
+
# → Python 3.12, uv activados ✨
|
|
1488
|
+
python --version # 3.12.1
|
|
1489
|
+
|
|
1490
|
+
cd ~/proyectos/api-go
|
|
1491
|
+
# → Go 1.22 activado ✨
|
|
1492
|
+
go version # go1.22.0
|
|
1493
|
+
|
|
1494
|
+
# SIN HACER NADA MANUAL 🎉
|
|
1495
|
+
```
|
|
1496
|
+
|
|
1497
|
+
---
|
|
1498
|
+
|
|
1499
|
+
## 📦 Scripts Mejorados con Mise
|
|
1500
|
+
|
|
1501
|
+
### scripts/test-changed.sh (optimizado con Mise)
|
|
1502
|
+
|
|
1503
|
+
```bash
|
|
1504
|
+
#!/usr/bin/env bash
|
|
1505
|
+
# scripts/test-changed.sh - Solo tests de archivos modificados
|
|
1506
|
+
|
|
1507
|
+
set -e
|
|
1508
|
+
|
|
1509
|
+
echo "🧪 Running tests on changed files..."
|
|
1510
|
+
|
|
1511
|
+
# Obtener archivos modificados (staged)
|
|
1512
|
+
CHANGED_FILES=$(git diff --cached --name-only --diff-filter=ACM)
|
|
1513
|
+
|
|
1514
|
+
if [ -z "$CHANGED_FILES" ]; then
|
|
1515
|
+
echo "No files changed, skipping tests"
|
|
1516
|
+
exit 0
|
|
1517
|
+
fi
|
|
1518
|
+
|
|
1519
|
+
# Detectar stack usando Mise
|
|
1520
|
+
if mise current node &> /dev/null; then
|
|
1521
|
+
# TypeScript/JavaScript
|
|
1522
|
+
echo "📦 Detected TypeScript/JavaScript project"
|
|
1523
|
+
|
|
1524
|
+
TEST_FILES=$(echo "$CHANGED_FILES" | grep -E '\.(ts|js|tsx|jsx)$' | \
|
|
1525
|
+
sed 's/src/tests/' | \
|
|
1526
|
+
sed 's/\.ts$/.test.ts/' | \
|
|
1527
|
+
sed 's/\.js$/.test.js/' | \
|
|
1528
|
+
xargs -I {} find . -name $(basename {}) 2>/dev/null || true)
|
|
1529
|
+
|
|
1530
|
+
if [ -n "$TEST_FILES" ]; then
|
|
1531
|
+
if command -v bun &> /dev/null; then
|
|
1532
|
+
bun test $TEST_FILES
|
|
1533
|
+
else
|
|
1534
|
+
npm test -- $TEST_FILES
|
|
1535
|
+
fi
|
|
1536
|
+
else
|
|
1537
|
+
echo "No test files found for changed files"
|