RuleStack

Configs

Stacks

Compare

Diff

RuleStack

Configs

Stacks

Compare

Diff

Read API

RuleStack

Configs

Stacks

Compare

Diff

Read API

Diff/opf-openproject-app-agents ↔ opf-openproject-spec-agents

Comparison

A · AGENTS.md · opf/openprojectB · AGENTS.md · opf/openproject
What each file covers, counted
DimensionSharedOnly in AOnly in BOverlap
Sections1559%
Commands0040%
Section tags20167%

What each file covers

Sections

1 shared · 5 only in A · 5 only in B
  • − App
  • − Code Style Guidelines
  • − Ruby
  • − Templates
  • − Translations
  • + Spec
  • + Running Tests
  • + Backend (RSpec) - prefer specific tests over running all
  • + Docker
  • + Debugging CI Failures
  •   Directory Structure

Commands

0 shared · 0 only in A · 4 only in B
  • + bundle exec rspec spec/models/user_spec.rb
  • + bundle exec rspec spec/models/user_spec.rb:42
  • + bundle exec rspec spec/features
  • + bundle exec rake parallel:spec

Section tags

2 shared · 0 only in A · 1 only in B
  • + test
  •   code-style
  •   architecture

Line diff

+24 added−22 removed9 unchanged27.3% identical
opf/openproject · app/AGENTS.md
@@ −1 @@
1# App
2 
3## Directory Structure
4 
5- `app/components/` - ViewComponent-based UI components (Ruby + ERB)
6- `app/contracts/` - Validation and authorization contracts
7- `app/controllers/` - Rails controllers
8- `app/models/` - ActiveRecord models
9- `app/services/` - Service objects (business logic)
10- `app/workers/` - Background job workers
11 
12## Code Style Guidelines
13 
14### Ruby
15- Follow [Ruby community style guide](https://github.com/bbatsov/ruby-style-guide)
16- Use service objects for complex business logic (return `ServiceResult`)
17- Use contracts for validation and authorization
18- Keep controllers thin, models focused
19- Document with [YARD](https://yardoc.org/)
20- Write RSpec tests for all new features
21- **Work package identifiers**: `WorkPackage.find("PROJ-42")` resolves semantic identifiers transparently. Use `find_by_display_id` only when input could legitimately be numeric OR semantic (controllers, URL-driven components, macro resolvers). Low-level code (queries, filters, services) should stick to `find_by(id:)` with primary keys. See `app/models/work_package/semantic_identifier/finder_methods.rb`.
22 
23### Templates
24- Use ERB for server-rendered views
25- Use ViewComponents for reusable UI (with Lookbook previews)
26- Lint with erb_lint before committing
27 
28## Translations
 
 
 
29 
30- UI strings must use translation keys (never hard-coded)
 
 
 
 
 
31 
opf/openproject · spec/AGENTS.md
@@ +1 @@
1# Spec
2 
3## Directory Structure
4 
5- `spec/features/` - System/feature tests (Capybara)
6- `spec/models/` - Model unit tests
7- `spec/requests/` - API/integration tests
8- `spec/services/` - Service tests
 
 
9 
10## Running Tests
11 
12```bash
13# Backend (RSpec) - prefer specific tests over running all
14bundle exec rspec spec/models/user_spec.rb # Single file
15bundle exec rspec spec/models/user_spec.rb:42 # Single line
16bundle exec rspec spec/features # Directory
17bundle exec rake parallel:spec # Parallel execution
18```
 
19 
20### Docker
 
 
 
21 
22```bash
23bin/compose rspec spec/models/user_spec.rb # Run specific tests in backend-test container
24bin/compose exec backend bundle exec rspec # Run tests directly in backend container
25```
26 
27## Debugging CI Failures
28 
29```bash
30./script/github_pr_errors | xargs bundle exec rspec # Run failed tests from CI
31./script/bulk_run_rspec spec/path/to/flaky_spec.rb # Run tests multiple times
32```
33 
@@ −1 +1 @@
1−# App
1+# Spec
22  
33 ## Directory Structure
44  
5−- `app/components/` - ViewComponent-based UI components (Ruby + ERB)
6−- `app/contracts/` - Validation and authorization contracts
7−- `app/controllers/` - Rails controllers
8−- `app/models/` - ActiveRecord models
9−- `app/services/` - Service objects (business logic)
10−- `app/workers/` - Background job workers
5+- `spec/features/` - System/feature tests (Capybara)
6+- `spec/models/` - Model unit tests
7+- `spec/requests/` - API/integration tests
8+- `spec/services/` - Service tests
119  
12−## Code Style Guidelines
10+## Running Tests
1311  
14−### Ruby
15−- Follow [Ruby community style guide](https://github.com/bbatsov/ruby-style-guide)
16−- Use service objects for complex business logic (return `ServiceResult`)
17−- Use contracts for validation and authorization
18−- Keep controllers thin, models focused
19−- Document with [YARD](https://yardoc.org/)
20−- Write RSpec tests for all new features
21−- **Work package identifiers**: `WorkPackage.find("PROJ-42")` resolves semantic identifiers transparently. Use `find_by_display_id` only when input could legitimately be numeric OR semantic (controllers, URL-driven components, macro resolvers). Low-level code (queries, filters, services) should stick to `find_by(id:)` with primary keys. See `app/models/work_package/semantic_identifier/finder_methods.rb`.
12+```bash
13+# Backend (RSpec) - prefer specific tests over running all
14+bundle exec rspec spec/models/user_spec.rb # Single file
15+bundle exec rspec spec/models/user_spec.rb:42 # Single line
16+bundle exec rspec spec/features # Directory
17+bundle exec rake parallel:spec # Parallel execution
18+```
2219  
23−### Templates
24−- Use ERB for server-rendered views
25−- Use ViewComponents for reusable UI (with Lookbook previews)
26−- Lint with erb_lint before committing
20+### Docker
2721  
28−## Translations
22+```bash
23+bin/compose rspec spec/models/user_spec.rb # Run specific tests in backend-test container
24+bin/compose exec backend bundle exec rspec # Run tests directly in backend container
25+```
2926  
30−- UI strings must use translation keys (never hard-coded)
27+## Debugging CI Failures
28+ 
29+```bash
30+./script/github_pr_errors | xargs bundle exec rspec # Run failed tests from CI
31+./script/bulk_run_rspec spec/path/to/flaky_spec.rb # Run tests multiple times
32+```
3133  
RuleStack

Built by

Kynth Studio

Directory

Configs
Stacks
Compare formats
Diff two configs
Best AGENTS.md examples

Formats

AGENTS.md
CLAUDE.md
Cursor rules
Copilot instructions

Reference

Read API
Corpus health
Privacy Policy
Terms

RuleStack

RuleStack

Built by

Kynth Studio

Directory

Configs
Stacks
Compare formats
Diff two configs
Best AGENTS.md examples

Formats

AGENTS.md
CLAUDE.md
Cursor rules
Copilot instructions

Reference

Read API
Corpus health
Privacy Policy
Terms

RuleStack

RuleStack

Built by

Kynth Studio

Directory

Configs
Stacks
Compare formats
Diff two configs
Best AGENTS.md examples

Formats

AGENTS.md
CLAUDE.md
Cursor rules
Copilot instructions

Reference

Read API
Corpus health
Privacy Policy
Terms

RuleStack