Objective-C

Execute these commands after EVERY implementation (see AGENT_AUTOMATION module for full workflow).

11 stars

Best use case

Objective-C is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Execute these commands after EVERY implementation (see AGENT_AUTOMATION module for full workflow).

Teams using Objective-C should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/objectivec/SKILL.md --create-dirs "https://raw.githubusercontent.com/hivellm/rulebook/main/templates/skills/languages/objectivec/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/objectivec/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How Objective-C Compares

Feature / AgentObjective-CStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Execute these commands after EVERY implementation (see AGENT_AUTOMATION module for full workflow).

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

<!-- OBJECTIVEC:START -->
# Objective-C Project Rules

## Agent Automation Commands

**CRITICAL**: Execute these commands after EVERY implementation (see AGENT_AUTOMATION module for full workflow).

```bash
# Complete quality check sequence:
xcodebuild clean build    # Build verification
xcodebuild test -scheme YourScheme  # All tests
# clang static analyzer runs automatically in Xcode builds

# Security audit:
# Use Xcode's built-in analyzer or third-party tools
```

## Objective-C Configuration

**CRITICAL**: Use Modern Objective-C with ARC and strict warnings.

- **Version**: Xcode 15+
- **ARC**: Automatic Reference Counting required
- **Formatter**: clang-format
- **Testing**: XCTest
- **Analyzer**: clang static analyzer

## Code Quality Standards

### Mandatory Quality Checks

**IMPORTANT**: These commands MUST match your GitHub Actions workflows!

```bash
# Pre-Commit Checklist (MUST match .github/workflows/*.yml)

# 1. Format check (matches workflow)
clang-format --dry-run --Werror **/*.{h,m}

# 2. Static analysis (matches workflow)
xcodebuild analyze -scheme YourScheme -sdk iphonesimulator

# 3. Build (matches workflow)
xcodebuild build -scheme YourScheme -sdk iphonesimulator \
  ONLY_ACTIVE_ARCH=NO CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO

# 4. Run tests (matches workflow)
xcodebuild test -scheme YourScheme -sdk iphonesimulator \
  -destination 'platform=iOS Simulator,name=iPhone 15'

# If ANY fails: ❌ DO NOT COMMIT - Fix first!
```

**Why This Matters:**
- Example: Using `clang-format -i` locally but `--dry-run` in CI = failure

### Testing Example (XCTest)

```objective-c
@import XCTest;
#import "DataProcessor.h"

@interface DataProcessorTests : XCTestCase
@property (nonatomic, strong) DataProcessor *processor;
@end

@implementation DataProcessorTests

- (void)setUp {
    [super setUp];
    self.processor = [[DataProcessor alloc] initWithThreshold:0.5];
}

- (void)testProcessValidInput {
    NSArray *input = @[@1, @2, @3];
    NSArray *result = [self.processor process:input];
    
    XCTAssertNotNil(result);
    XCTAssertGreaterThan(result.count, 0);
}

- (void)testProcessHandlesNil {
    XCTAssertThrows([self.processor process:nil]);
}

@end
```

<!-- OBJECTIVEC:END -->

Related Skills

We are still matching the closest adjacent skills for this page. In the meantime, continue through the full directory.