agentleFS
giselles-aigiselles-ai/giselle/.cursor/rules/naming-guide.mdc

giselle / rules

Cursor rule556 starsChanged 12 months agoApache-2.0View on GitHub

Naming convention guide for Giselle codebase

The file

Show its rules and text

We split this naming-guide.mdc into the rules it gives an agent

13 rules. About 0 are common, 12 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈12

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    All filenames should use kebab-case (lowercase with hyphens)

    line 11
  2. Distinctive:

    Avoid abbreviations unless they are widely known

    line 38
  3. Distinctive:

    Use descriptive names that explain the purpose or behavior

    line 39
  4. Distinctive:

    Use verbs or verb phrases for function names

    line 42
  5. Distinctive:

    Avoid ambiguous names that could lead to misuse

    line 44
  6. Distinctive:

    Use nouns or noun phrases for variable names

    line 52
  7. Distinctive:

    Avoid single-letter variables except in very short scopes

    line 54
  8. Very specific:

    Use prefixes like is, has, can, should for both variables and functions returning boolean values

    line 62
  9. Distinctive:

    Follow consistent naming patterns across the codebase

    line 75
  10. Distinctive:

    Use the same terms for the same concepts

    line 76
  11. Distinctive:

    When someone reads your code, they should understand the purpose without additional context

    line 81
  12. Distinctive:

    Avoid names that could be misinterpreted or used incorrectly

    line 83
  13. Distinctive:

    Consider the perspective of other developers who will maintain or use your code

    line 84

≈ “Common” is an estimate: at least 1 in 5 of the 3,030 Cursor rule files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
naming-guide.mdc
---
description: Naming convention guide for Giselle codebase
globs: "**/*"
alwaysApply: true
---
# Naming Guide

## Case Conventions

1. **File Naming: kebab-case**
   - All filenames should use kebab-case (lowercase with hyphens)
   - Examples:
     - ✅ `user-profile.ts`
     - ✅ `api-client.tsx`
     - ❌ `UserProfile.ts`
     - ❌ `apiClient.tsx`

2. **Component Naming: PascalCase**
   - React components and classes should use PascalCase
   - Examples:
     - ✅ `UserProfile`
     - ✅ `ApiClient`
     - ❌ `userProfile`
     - ❌ `user-profile`

3. **Variable Naming: camelCase**
   - Variables, functions, and methods should use camelCase
   - Examples:
     - ✅ `userEmail`
     - ✅ `isActive`
     - ❌ `UserEmail`
     - ❌ `user-email`

## Core Principles

1. **Readability First**
   - Names should be self-explanatory and immediately understandable
   - Avoid abbreviations unless they are widely known
   - Use descriptive names that explain the purpose or behavior

2. **Function Naming**
   - Use verbs or verb phrases for function names
   - Names should clearly indicate what the function does
   - Avoid ambiguous names that could lead to misuse
   - Examples:
     - ✅ `calculateTotalPrice()`
     - ✅ `validateUserInput()`
     - ❌ `process()` (too vague)
     - ❌ `doStuff()` (unclear purpose)

3. **Variable Naming**
   - Use nouns or noun phrases for variable names
   - Names should describe what the variable represents
   - Avoid single-letter variables except in very short scopes
   - Examples:
     - ✅ `userEmail`
     - ✅ `isActive`
     - ❌ `x` (unless in a mathematical context)
     - ❌ `temp` (unless truly temporary)

4. **Boolean Variables and Functions**
   - Use prefixes like `is`, `has`, `can`, `should` for both variables and functions returning boolean values
   - Make the true/false meaning clear
   - For variables examples:
     - ✅ `isEnabled`
     - ✅ `hasPermission`
     - ❌ `status` (ambiguous boolean)
   - For function examples:
     - ✅ `isTriggerRequiringCallsign()`
     - ✅ `hasActiveSubscription()`
     - ❌ `requiresCallsign()` (less clear about boolean return type)
     - ❌ `checkActive()` (ambiguous about what's returned)

5. **Consistency**
   - Follow consistent naming patterns across the codebase
   - Use the same terms for the same concepts
   - Maintain consistent casing (camelCase, PascalCase, etc.)

## Best Practices

- When someone reads your code, they should understand the purpose without additional context
- Function names should make it clear how to use them correctly
- Avoid names that could be misinterpreted or used incorrectly
- Consider the perspective of other developers who will maintain or use your code

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.