<commit_before># KGNColor

`KGNColor` is a collection of helpful `UIColor` extensions.

[![iOS 8.0+](http://img.shields.io/badge/iOS-8.0%2B-blue.svg)]()
[![Xcode 7.0](http://img.shields.io/badge/Xcode-7.0-blue.svg)]()
[![Swift 2.0](http://img.shields.io/badge/Swift-2.0-blue.svg)]()
[![Release](https://img.shields.io/github/release/kgn/KGNColor.svg)](/releases)
[![Build Status](http://img.shields.io/badge/License-MIT-lightgrey.svg)](/LICENSE)

[![Build Status](https://travis-ci.org/kgn/KGNColor.svg)](https://travis-ci.org/kgn/KGNColor)
[![Carthage Compatible](https://img.shields.io/badge/Carthage-Compatible-4BC51D.svg)](https://github.com/Carthage/Carthage)
[![CocoaPods Version](https://img.shields.io/cocoapods/v/KGNColor.svg)](https://cocoapods.org/pods/KGNColor)
[![CocoaPods Platforms](https://img.shields.io/cocoapods/p/KGNColor.svg)](https://cocoapods.org/pods/KGNColor)

[![Twitter](https://img.shields.io/badge/Twitter-@iamkgn-55ACEE.svg)](http://twitter.com/iamkgn)

## Installing

### Carthage

Add `KGNColor` to your `Cartfile`.
```
github "kgn/KGNColor"
```

### CocoaPods

*TODO*

## Examples

### Hex Initializer
Using a hex value is often the easiest way to use the exact color from a design.
``` Swift
let tintColor = UIColor(hex: 0x2DFF5F)
```

### Components
Used this helpful tuple to get the `red`, `green`, `blue` and `alpha` values of a `UIColor`.

``` Swift
let tintColor = UIColor(hex: 0x2DFF5F)
print("red: \(tintColor.components.red)")
print("red: \(tintColor.components.green)")
print("red: \(tintColor.components.blue)")
```

### Invert a Color
``` Swift
let tintColor = UIColor(hex: 0x2DFF5F)
print("inverted tint: \(tintColor.testInvert())")
```

### Lighten a Color
``` Swift
let tintColor = UIColor(hex: 0x2DFF5F)
print("lightened tint: \(tintColor.lighten(0.5))")
```

### Darken a Color
``` Swift
let tintColor = UIColor(hex: 0x2DFF5F)
print("lightened tint: \(tintColor.darken(0.5))")
```

TODO:
- [ ] Travis
- [X] Badges
- [X] Tests
- [X] Carthage
- [X] CocoaPods
- [X] Description
- [ ] Documentation
<commit_msg>add CocoaPods to install instructions<commit_after># KGNColor

`KGNColor` is a collection of helpful `UIColor` extensions.

[![iOS 8.0+](http://img.shields.io/badge/iOS-8.0%2B-blue.svg)]()
[![Xcode 7.0](http://img.shields.io/badge/Xcode-7.0-blue.svg)]()
[![Swift 2.0](http://img.shields.io/badge/Swift-2.0-blue.svg)]()
[![Release](https://img.shields.io/github/release/kgn/KGNColor.svg)](/releases)
[![Build Status](http://img.shields.io/badge/License-MIT-lightgrey.svg)](/LICENSE)

[![Build Status](https://travis-ci.org/kgn/KGNColor.svg)](https://travis-ci.org/kgn/KGNColor)
[![Carthage Compatible](https://img.shields.io/badge/Carthage-Compatible-4BC51D.svg)](https://github.com/Carthage/Carthage)
[![CocoaPods Version](https://img.shields.io/cocoapods/v/KGNColor.svg)](https://cocoapods.org/pods/KGNColor)
[![CocoaPods Platforms](https://img.shields.io/cocoapods/p/KGNColor.svg)](https://cocoapods.org/pods/KGNColor)

[![Twitter](https://img.shields.io/badge/Twitter-@iamkgn-55ACEE.svg)](http://twitter.com/iamkgn)

## Installing

### Carthage

Add `KGNColor` to your `Cartfile`.
```
github "kgn/KGNColor"
```

### CocoaPods

```
pod 'KGNColor'
```

## Examples

### Hex Initializer
Using a hex value is often the easiest way to use the exact color from a design.
``` Swift
let tintColor = UIColor(hex: 0x2DFF5F)
```

### Components
Used this helpful tuple to get the `red`, `green`, `blue` and `alpha` values of a `UIColor`.

``` Swift
let tintColor = UIColor(hex: 0x2DFF5F)
print("red: \(tintColor.components.red)")
print("red: \(tintColor.components.green)")
print("red: \(tintColor.components.blue)")
```

### Invert a Color
``` Swift
let tintColor = UIColor(hex: 0x2DFF5F)
print("inverted tint: \(tintColor.testInvert())")
```

### Lighten a Color
``` Swift
let tintColor = UIColor(hex: 0x2DFF5F)
print("lightened tint: \(tintColor.lighten(0.5))")
```

### Darken a Color
``` Swift
let tintColor = UIColor(hex: 0x2DFF5F)
print("lightened tint: \(tintColor.darken(0.5))")
```

TODO:
- [ ] Travis
- [X] Badges
- [X] Tests
- [X] Carthage
- [X] CocoaPods
- [X] Description
- [ ] Documentation

{'fraction_non_alphanumeric': 0.20741097208854667, 'fraction_numerical': 0.0178055822906641, 'mean_word_length': 5.042151162790698, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 20, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 2, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1606181', 'n_tokens_mistral': 1799, 'n_tokens_neox': 1691, 'n_words': 281}