Upstream source of truth: https://github.com/scanalesespinoza/adev
A-Dev is the canonical operating doctrine for model- and agent-assisted software delivery. It consolidates the transferable system extracted from real execution, especially the high-friction operational lessons gathered in Homedir.
- Use this file as the upstream source of truth for all downstream
ADEV.mdcopies. - Keep downstream copies synchronized with this file unless a repository requires an explicitly documented local overlay.
- Treat Homedir as the proving ground and A-Dev as the reusable operating system.
- Default mode: each iteration must ship from a dedicated branch and a single atomic PR with a clear objective.
- Every change must land through a PR; direct pushes to
mainare not allowed. - Commits must be atomic and use Conventional Commits.
- Do not mix refactor, feature, visual changes, infrastructure, doctrine updates, and release mechanics in the same PR unless batch delivery is explicitly requested.
- Prefer new canonical assets over broad rewrites of stable files when codifying new lessons.
- Every framework claim must map to a repository asset, validated release flow, or real operational evidence.
- Every failure worth remembering must become one of: a guardrail, a case study, a checklist item, a starter-kit update, or a durable rule.
- English is the only valid language for committed repository content unless a bilingual mirror is explicitly required.
- If another person or agent is already changing a file locally, avoid parallel edits on that file unless coordination is explicit.
- Do not institutionalize guessed workflows. If the repository or evidence does not support a claim, mark it as a gap.
- Run the narrowest validation that proves the change is sound for its scope before commit.
- CI must be green before merge.
- Do not advance to a new iteration without validating the previous one in production when the change has production impact.
- Versioning and tagging happen on a manual initiative cadence; do not assume a tag or public release for every PR or minor change.
- When versioning, update version references across the repository, starting with the canonical version source such as
pom.xmlwhen applicable. - Every result must be followed through to deployment verification, not left at analysis or local edits only.
- For new features, endpoints, or APIs, use a mandatory 3-iteration incremental rollout: hidden or non-production, progressive integration, then legacy cleanup after production validation.
- If the project is multilingual, all visible text must be implemented through language bundles or equivalent localization assets; avoid globally hardcoded text in templates, JS, backend code, and UI messages.
- If batch delivery is explicitly requested, multiple atomic iterations may live in one PR, but each stage still requires explicit validation and a rollback point.
- Every PR failure, integration block, or incident caused by a change must be closed by incorporating the resulting learning into this upstream rule set or another durable canonical asset.
- Every change touching templates, visible copy, i18n, public routes, or admin views must update or create tests for the affected behavior in the same iteration.
- Before opening a PR, review changes against common security and CodeQL patterns such as logs with input or paths, redirects, auth or session, persistence, and input-derived URLs; sanitize or encapsulate those cases in the same iteration.
- Marketing automation and social publishing require staged rollout: internal drafts, controlled approval or scheduling, then autopublishing only after production validation.
- Automated marketing may use only real and verifiable product data; never invent numbers, milestones, or claims.
- Every integration with external publishing or automation channels must use secrets managed outside the repository, deduplication, channel rate limiting, and a global kill switch before any production scheduler is enabled.
- Every iteration, batch, or objective must end with an updated handoff in the shared workspace and an open or updated PR when that workspace model is part of the repository operating system.
- The shared workspace must remain consistent at relevant checkpoints, including
LATEST.txt,HANDOFF.md,state.json,SESSION-LOG.md, andDECISIONS.mdwhen those assets exist in the repo. - Before requesting approval, merge, or production promotion, complete the quality tasks needed to sustain high PR success: local validation, targeted tests, risk preflight, and updated verification notes.
- Every PR should be configured with auto-merge when the repository workflow supports it, unless an explicit documented blocker prevents it.
- Every change must finish in a PR at the close of an iteration or objective; do not leave completed work only in a local branch, local handoff, or chat transcript.
- Every approved and merged PR to
mainmust end with operational cleanup: verify the merge, update handoff if used, and remove no-longer-needed source branches. - Any local branch already merged into
mainmust be deleted during cleanup unless it is still attached to an active worktree or another documented hold condition. - PR quality, release gates, and production-promotion validations belong to the SDLC and delivery operation, not to the user-facing product, unless explicitly scoped otherwise.
- If there is an active PRD or product roadmap, iterations must prioritize visible end-user value and avoid diverting scope toward internal tooling, release evidence, or operational layers that are outside the agreed product.
- Keep canonical public content understandable without requiring private chat context.
- The strongest material in this system is disciplined learning under failure, delivery pressure, and verification, not abstract optimism.
- Convert operational evidence into reusable doctrine.
- Favor evidence indexes, guardrails, and failure-derived case studies.
- Improve starter-kit adoption paths, rituals, templates, and reusable operating assets.
- Make A-Dev portable beyond the original proving ground.
- Expand the manuscript, proof packaging, and positioning.
- Strengthen external credibility without diluting the framework.
- Sync with
origin/mainand open a dedicated branch with explicit scope. - Define the exact scope for the current iteration, stage, or PR.
- Choose the delivery mode: default one-iteration-one-PR, or explicit batch delivery.
- Implement only the agreed scope for the iteration or current batch stage.
- For new features, endpoints, or APIs, use the incremental rollout sequence: hidden or unused -> integrated or consumed -> legacy cleanup or deprecation.
- In batch delivery mode, create a restore point at the start of the batch and maintain checkpoints by stage.
- Validate the changed surface with the narrowest meaningful build, test, or review step.
- Commit atomically.
- Push the branch.
- Update the shared workspace handoff before requesting review or changing assistant or session, when that workspace model exists.
- Create or update the PR with summary, why, scope in/out, validation, production verification plan, rollback plan, and follow-up stage when relevant.
- Enable auto-merge when checks are ready and approval requirements are satisfied.
- Monitor PR validation and any required release or production workflows.
- Before merge or production promotion, run and record validations focused on scope, including targeted UI, i18n, backend, and operational tests when applicable.
- If a quality gate, readiness, or release-evidence need appears, solve it in the SDLC and delivery layer through scripts, CI, operational docs, runbooks, or shared handoff unless product scope explicitly says otherwise.
- After approval and merge, verify the deployed behavior in production or the highest relevant target environment.
- After merge verification, delete local branches already merged into
mainas part of routine cleanup. - Update handoff again with merge result, verification result, and cleanup when the repo uses a shared workspace model.
- If production fails, stop new iterations, revert or roll back to a stable version, and open a corrective PR with root cause and prevention.
- Prefer proof chains of the form: incident -> decision -> guardrail -> reusable asset.
- When using project-specific source material such as Homedir, extract the transferable principle; do not let project-specific detail replace doctrine.
- Case studies should show conflict, constraint, decision, evidence, and reusable lesson.
- Starter-kit assets should tell a practitioner what to do on day 0, in the first week, and before the first production release.
- Traceability matters: roadmap, doctrine, templates, runbooks, and releases should agree with each other.
- If a rule, template, or automation contradicts the actual repository flow, fix the rule or documentation first before institutionalizing the error.
- Document and automate only commands, workflows, and assumptions backed by the repository or real operation; if context is missing, mark it explicitly as
TODO. - For scripts, operations, and disaster recovery, syntactic validation is not enough: run real smoke tests in the environment that matters and separate harness failures from functional failures.
- For performance work, compare apples to apples against a concrete baseline, measure latency, error, and payload, and state uncertainty when fixtures, traces, or production data are missing.
- Always prioritize the highest-leverage fix demonstrated by evidence; avoid broad optimizations or redesigns without measurement that justifies them.
- For visual customizations by event or context, apply branding overrides only within that scope and preserve the global product identity outside it.
- For backup and disaster recovery, validate full restorability of the service; a backup is not sufficient unless the service can actually be reconstructed with tested procedure and artifacts.
- Keep workstreams clean: branch from a stable base, avoid mixing unrelated changes, and revalidate whenever flags, commands, or tools change.
- In multilingual pages, tests must pin the expected locale explicitly and validate the corresponding localized content.
- When the narrative, hierarchy, or copy of a view changes, review sibling tests of the same resource as well so outdated expectations do not survive until CI.
- When a refactor changes the UI interaction model, update tests in the same iteration to validate the new observable behavior and remove dependencies on legacy markup.
- If a change introduces new logs about routes, identifiers, or values derived from input or state, record only sanitized labels and not absolute paths or raw values.
- When shared services already write fields to logs, treat those fields as indirect security sinks and use constant or sanitized identifiers for auxiliary attributes.
- If workflows or checks emit runtime or deprecation warnings, treat them as operational debt: update supported actions or dependencies before adding more capability.
- In social marketing, validate drafts and claims internally before linking external channels; higher-risk networks should remain in explicit-approval mode until sustained quality is proven.
- When an admin or public view derives summaries or statuses from optional codes, re-sanitize the value after each derived assignment and cover the exact production state in tests to avoid null-handling defects.
- Do not turn PR stabilization, production-promotion steps, or rollout tracking needs into product features unless there is an explicit business requirement.
- Production releases should not depend on a single container registry; keep at least one secondary registry operational for push and pull.
- Homedir is the main proving ground for this doctrine.
- When operating specifically in Homedir, keep the shared handoff workspace current and verify public-site behavior after merge.
- Homedir-specific validation targets such as
/,/comunidad,/eventos, and/proyectosremain valid as project-level checks, not universal A-Dev requirements.
- Homedir is the proving ground. A-Dev is the transferable system.
- The book, doctrine, and starter kit should not depend on private chat context to make sense.
- The most valuable content in this repository is disciplined learning under failure, delivery pressure, and verification.