Course contents
Antigravity CLI rules and skills: GEMINI.md, AGENTS.md and .agents/
On this page
Antigravity CLI replaced Gemini CLI for personal accounts
On June 18, 2026, Gemini CLI stopped serving requests for free, Google AI Pro and Google AI Ultra personal accounts. Google's path forward is Antigravity CLI, run with agy (Gemini CLI announcement, Google Developers Blog). Enterprise Gemini Code Assist licenses and API-key use of Gemini CLI were not affected.
Your GEMINI.md files carry over unchanged. Workspace skills moved: .gemini/skills/ becomes .agents/skills/ (migration guide).
Where rules go
Antigravity reads rules from your start folder and each parent folder up to the repo root (Antigravity rules):
| File | Frontmatter | Loads |
|---|---|---|
AGENTS.md or GEMINI.md | None | Always |
.agents/AGENTS.md or .agents/GEMINI.md | None | Always |
.agents/rules/*.md | Required trigger | Depends on trigger |
Global rules: ~/.gemini/AGENTS.md, ~/.gemini/GEMINI.md, ~/.gemini/config/AGENTS.md, ~/.gemini/config/GEMINI.md, or ~/.gemini/config/rules/*.md.
Rules are cumulative. Antigravity combines everything it finds, so the same text in both GEMINI.md and AGENTS.md loads twice.
It doesn't load rules from subfolders below the start folder, even when the agent edits files there. Start agy in the folder whose rules you need, or keep shared rules at the root.
Rule files with triggers
Files in .agents/rules/ must start with frontmatter and a valid trigger. A missing or misspelled trigger (like alwaysOn) means the rule is silently discarded.
---
trigger: model_decision
description: "Apply when writing or reviewing database migrations or schema changes."
---
- Never drop or rename a column in one deploy. Use expand and contract.
- Create indexes on existing Postgres tables with CONCURRENTLY.
trigger | Behavior |
|---|---|
always_on | Full content every turn |
model_decision | Only path and description up front; the agent reads the rule when relevant |
glob | Activates for files matching globs (quote patterns that start with *) |
manual | Only on @ mention; Antigravity CLI doesn't support rule mentions |
Only files directly inside .agents/rules/ are scanned. .agents/rules/frontend/react.md is skipped unless you list it in .agents/rules.json.
Size limits
- 24,000 bytes per rule file. Anything past that is truncated.
- 20,000 tokens for all always-on and global rules combined. Over budget, Antigravity demotes the largest files to pointers the agent reads on demand.
Including files
@[label](path) inlines another file's contents into a rule. Plain @path doesn't inline; it gives the agent an exact file reference.
Skills: .agents/skills/
| Location | Scope |
|---|---|
.agents/skills/<name>/ | Workspace (and each parent folder up to the repo root) |
~/.gemini/config/skills/<name>/ | Global, shared with the Antigravity App |
~/.gemini/antigravity-cli/skills/, ~/.gemini/skills/ | Global, CLI only; these take priority over same-named skills elsewhere |
Every skill becomes a slash command automatically: a skill named deploy-staging gives you /deploy-staging (Antigravity skills). If you add a skill while the CLI is running, run /skills reload. Skill folders must sit directly inside skills/.
Install a preset
npx presets-dev add nextjs --tool antigravitycreated GEMINI.md
created .agents/skills/nextjs-code-review/SKILL.md
2 file action(s), 0 skipped. https://presets.dev
The standards are appended to GEMINI.md inside presets.dev markers, and your existing content is kept. To append to AGENTS.md instead, for example because Codex already uses it, add --agents-md:
npx presets-dev add nextjs --tool antigravity --agents-mdUse one or the other, never both. The skill goes to the shared .agents/skills/ folder, which Codex reads too, so it's written once even if you install for both tools.
Preview: Next.js rules for Antigravity CLI and Next.js code review skill for Antigravity CLI.
Check that it loaded
/contextopens a token breakdown with rows for Rules and Skills, plus tracked system files such asGEMINI.mdand.agents/rules/(/context docs)./rulesand/skillslist what's active. In the/skillspanel, press Enter on a skill to see its path and instructions.
Common mistakes
- Same section in
GEMINI.mdandAGENTS.md. Both load. Pick one. - Leftover
.gemini/skills/. Antigravity CLI reads.agents/skills/for workspace skills. Move the folder. - Rules in subfolders below the start folder. They don't load. Start
agycloser to the code, or move the rule up. - camelCase triggers.
alwaysOnandmodelDecisionare invalid; usealways_onandmodel_decision.
Recap
- Antigravity CLI (
agy) replaced Gemini CLI for personal accounts on June 18, 2026. GEMINI.mdandAGENTS.mdare both always on and cumulative; use one for a given section..agents/rules/*.mdneed a validtrigger;.agents/skills/holds skills that become slash commands.- Limits: 24,000 bytes per rule file and 20,000 tokens of always-on rules.
Next step
You've seen all seven tools. Now learn to write a rule that changes behavior.