Latest 0.0.2
Homepage https://github.com/dduan/cURLLook
License MIT
Platforms ios 8.0, osx 10.10
Authors

This μ-framework serializes your NSURLRequest object to
a cURL command, so you can convey to a backend person
clearly what kind of HTTP request your code is making.

let request: NSURLRequest
let aSession: NSURLSession

// … after you created your URL session and request, this will give you
// a cURL command that also performs this request
print(request.cURLRepresentation(withURLSession: aSession))

// alternatively, you can use this convenient proprety without a session:
print(request.cURLString)

Install

Carthage (recommended)

Include the following in your Cartfile:

github "dduan/cURLLook"

CocoaPods

The usual way:

platform :ios, '8.0'
use_frameworks!

target 'MyApp' do
  pod 'cURLLook'
end

Credit

The code is an adaption from
Alamofile

Latest podspec

{
    "name": "cURLLook",
    "version": "0.0.2",
    "summary": "Make your NSURLRequest a cURL command",
    "description": "This u03bc-framework serializes your NSURLRequest object tona cURL command, so you can convey to a backend personnclearly what kind of HTTP request your code is making.",
    "homepage": "https://github.com/dduan/cURLLook",
    "license": {
        "type": "MIT",
        "file": "LICENSE.md"
    },
    "authors": {
        "Daniel Duan": "[email protected]"
    },
    "social_media_url": "https://twitter.com/Daniel_Duan",
    "platforms": {
        "ios": "8.0",
        "osx": "10.10"
    },
    "source": {
        "git": "https://github.com/dduan/cURLLook.git",
        "tag": "v0.0.2"
    },
    "source_files": [
        "cURLLook",
        "cURLLook/**/*.{swift}"
    ]
}

Pin It on Pinterest

Share This