Skip to content

Commit

Permalink
More README updates and fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
robbywalker committed Jun 29, 2013
1 parent 08a9fb4 commit 98a8e20
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion README.md
Expand Up @@ -9,15 +9,19 @@ pip install ocstyle

# Example

If you have a file called `test.m` like this:

```objc
+(void) someMessage:(NSString*)subdomain {
NSString *ShouldStartLowerCase;
// ...
}
```

You can check style in it like this:

```
$ oclint test.m
$ ocstyle test.m
test.m
ERROR: 1:1 [1] - MissingSpace - Expected 1, got 0
ERROR: 1:8 [8] - ExtraSpace - Did not expect ' ' here
Expand All @@ -32,6 +36,10 @@ ERROR: 2:35 [77] - BadLocalVariableName - Local variable must start with a lower
Make it easy to share and enforce style rules for Objective C. The less human time we spend thinking about whitespace
and naming the better! Also enforces the existence of basic documentation.

At [Cue](http://www.cueup.com) we use this as a
[git pre-commit hook](http://git-scm.com/book/en/Customizing-Git-Git-Hooks).
This way we ensure everyone maintains a consistent coding style with a minimum of effort.

# Related

[OCLint](http://oclint.org/) runs static analysis that helps to detect common logic errors. Use it alongside ocstyle!
Expand Down

0 comments on commit 98a8e20

Please sign in to comment.