This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.
To capture the video (filesize: 19MB), using the free "QuickTime Player" application:
import Foundation | |
import Dispatch | |
// Special queue for flushing the logs | |
private let loggingQueue = DispatchQueue(label: "com.logging.queue", qos: .utility) | |
// The application-wide logger object | |
public var logger: Logger = GlobalLogger.global | |
// A global logger which flushes data using the loggingQueue |
// | |
// Punycode.swift | |
// | |
// Created by Mike Kasianowicz on 9/7/15. | |
// Copyright © 2015 Mike Kasianowicz. All rights reserved. | |
// | |
import Foundation | |
public class Punycode { |
// This could be done using CALayer cornerRadius property | |
// This is an example of how would be done without that :-) | |
@interface UIImage (RoundedCorners) | |
- (UIImage *)roundedImageWithCornerRadius:(CGFloat)cornerRadius; | |
@end | |
@implementation UIImage (RoundedCorners) |
// Taken from http://PSPDFKit.com. This snippet is under public domain. | |
#define UIKitVersionNumber_iOS_7_0 0xB57 | |
BOOL PSPDFIsUIKitFlatMode(void) { | |
static BOOL isUIKitFlatMode = NO; | |
static dispatch_once_t onceToken; | |
dispatch_once(&onceToken, ^{ | |
// We get the modern UIKit if system is running >= iOS 7 and we were linked with >= SDK 7. | |
if (kCFCoreFoundationVersionNumber >= kCFCoreFoundationVersionNumber_iOS_7_0) { | |
isUIKitFlatMode = (NSVersionOfLinkTimeLibrary("UIKit") >> 16) >= UIKitVersionNumber_iOS_7_0; | |
} |
# | |
# Uncrustify Configuration File | |
# File Created With UncrustifyX 0.2 (140) | |
# | |
# Alignment | |
# --------- | |
## Alignment |
{ | |
"selector": "source.ts", | |
"cmd": ["tsc", "$file"], | |
"file_regex": "^(.+?) \\((\\d+),(\\d+)\\)(: .+)$", | |
"line_regex": "\\((\\d+),(\\d+)\\)", | |
"osx": { | |
"path": "/usr/local/bin:/opt/local/bin" |
tell application "iPhone Simulator" | |
activate | |
end tell | |
tell application "System Events" | |
tell process "iPhone Simulator" | |
tell menu bar 1 | |
tell menu bar item "iOS Simulator" | |
tell menu "iOS Simulator" | |
click menu item "Reset Content and Settings…" |