From 1d34939dd387eca3127a78c216be1c96fa4c5780 Mon Sep 17 00:00:00 2001 From: Rafli <93827765+raf-li@users.noreply.github.com> Date: Fri, 2 Oct 2026 12:34:49 +0700 Subject: [PATCH] Add AGENTS.md for AI coding agents AGENTS.md holds the team's rules for any AI coding agent (Claude Code, Codex, Copilot, Cursor, Gemini, ...): accessibility first, no committed secrets, no direct pushes to main, ask before publishing or destructive actions, never post in other people's repositories (NV Access bans AI tools from the Add-on Store repository), and stay transparent about AI involvement. It has sections to fill in with the project's own commands and notes. CLAUDE.md just imports it, so there is one source of truth. The README mentions both, and no longer asks to have the main branch protected by hand: the organization does that automatically now. Co-Authored-By: Claude Opus 5.5 --- AGENTS.md | 31 +++++++++++++++++++++++++++++++ CLAUDE.md | 1 + README.md | 7 +++++-- 3 files changed, 37 insertions(+), 2 deletions(-) create mode 100644 AGENTS.md create mode 100644 CLAUDE.md diff --git a/AGENTS.md b/AGENTS.md new file mode 100644 index 0000000..99b3649 --- /dev/null +++ b/AGENTS.md @@ -0,0 +1,31 @@ +# Instructions for AI coding agents + +This file is read by AI coding agents (Claude Code, Codex, GitHub Copilot, Cursor, Gemini and others) working in this repository. People should start with the README and the [InfiArtt contributing guide](https://github.com/InfiArtt/.github/blob/main/CONTRIBUTING.md). + +## About this project + + + +## Commands + + + +- Python: `pip install -r requirements.txt`, then `pytest`. CI also runs `python -m compileall -q .`. +- Node.js: `npm ci`, then `npm run lint`, `npm run build` and `npm test`. + +Run the tests before committing, and add a test when you fix a bug. + +## Rules + +- **Accessibility first.** InfiArtt is led by people with disabilities. Every control needs a label that screen readers announce, everything must work with the keyboard alone, and messages should say clearly what happened and what to do next. +- **Never commit secrets**: passwords, API keys, tokens, `.env` files. Push protection blocks known kinds of secrets, but don't rely on it. +- **Don't push to `main`.** Work on a branch and open a pull request. +- **Ask first** before anything that publishes or can't easily be undone: merging, releases, tags, deployments, package uploads, force-pushing, deleting branches or repositories. +- **Never post in other people's repositories** (issues, comments, pull requests, submissions) on the team's behalf. Some communities forbid AI tools from interacting with them; NV Access, for example, bans them from the NVDA Add-on Store repository. Prepare the facts and leave the posting to a person. +- **Be transparent about AI involvement.** Keep `Co-Authored-By` trailers in commits, and don't disguise AI-written text as written by a person. +- Keep changes focused, and match the existing code style, naming and comment density. +- Write code, comments and commit messages in English, with Conventional Commits prefixes (`feat:`, `fix:`, `docs:`, `test:`, `ci:`, `refactor:`). Talk to the team in the language they use with you, often Indonesian. + +## Project-specific notes + + diff --git a/CLAUDE.md b/CLAUDE.md new file mode 100644 index 0000000..43c994c --- /dev/null +++ b/CLAUDE.md @@ -0,0 +1 @@ +@AGENTS.md diff --git a/README.md b/README.md index d60eb13..c0cf2d2 100644 --- a/README.md +++ b/README.md @@ -9,14 +9,17 @@ This repository is the starting point for new InfiArtt projects. On GitHub, choo - **CI** (`.github/workflows/ci.yml`): on every push to `main` and every pull request, it checks Python code (installs requirements, checks that every file compiles, runs `pytest` if there is a `tests` folder) and Node.js code (installs, then runs the `lint`, `build` and `test` scripts if they exist). Steps for a language you don't use are skipped. - **Dependabot** (`.github/dependabot.yml`): weekly pull requests that keep the GitHub Actions used by CI up to date. Add your package ecosystem (pip, npm, ...) there once the project has dependencies. - A **`.gitignore`** for Python, Node.js, editors and operating systems. +- **`AGENTS.md`** (and `CLAUDE.md`, which loads it): instructions for AI coding agents such as Claude Code, Codex or Copilot. Agents read it automatically, so the team's rules apply whichever tool someone uses. Issue forms, the pull request template and the contributing guide come from the organization automatically. After creating your repository: 1. Replace this README with one about your project. -2. Add a license if the project needs one (**Add file** > **Create new file** > name it `LICENSE`, then **Choose a license template**). -3. Ask an organization owner to protect the `main` branch, if that hasn't been done yet. +2. Fill in the project sections of `AGENTS.md` (what it is, the real commands), and add notes there as you learn them. +3. Add a license if the project needs one (**Add file** > **Create new file** > name it `LICENSE`, then **Choose a license template**). + +Public repositories get secret scanning and push protection as soon as they are created, and protection for the default branch (no deleting it, no force-pushing) within a day. ## Contributing