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:
indirect enum LinkedList<T> { | |
case Empty | |
case Node(value: T, next: LinkedList<T>) | |
init() { self = .Empty } | |
} | |
extension LinkedList { | |
func cons(x: T) -> LinkedList<T> { | |
return .Node(value: x, next: self) |
// | |
// Storage.swift | |
// | |
// Created by Grigory Avdyushin on 30.06.16. | |
// Copyright © 2016 Grigory Avdyushin. All rights reserved. | |
// | |
import UIKit | |
import CoreData |
# | |
# ZSH, Mac OS X or Ubuntu | |
# | |
# Decode base 64 and convert into hex string | |
echo 'aGI32ansgxzKWh3RV4EjRwQsW1v1la+7NBTdjx8zYq0=' | base64 -D | hexdump -ve '1/1 %.2x' | pbcopy | |
# Get dirs sizes in one level and sort them | |
du --max-depth=1 -h | sort -n |
let string = "www." | |
func hasPrefix(_ prefix: String) -> (String) -> Bool { | |
return { value in value.hasPrefix(prefix) } | |
} | |
func ~=(block: (String) -> Bool, string: String) -> Bool { | |
return block(string) | |
} |
extension Character { | |
var asciiValue: Int { | |
get { | |
let s = String(self).unicodeScalars | |
return Int(s[s.startIndex].value) | |
} | |
} | |
} |
// | |
// DisplayLink.swift | |
// | |
// Created by Jose Canepa on 8/18/16. | |
// Copyright © 2016 Jose Canepa. All rights reserved. | |
// Updated by Grigory Avdyushin on 3/6/19. | |
// Copyright © 2019 Grigory Avdyushin. All rights reserved. | |
// | |
import AppKit |
#!/usr/bin/python | |
import fileinput | |
version = "kjv" | |
header = """-- | |
-- | |
-- |
class Tests: XCTestCase { | |
override func setUp() { | |
super.setUp() | |
} | |
override func tearDown() { | |
super.tearDown() | |
} | |
} |
#!/usr/bin/python | |
# coding: utf8 | |
import io | |
import re | |
import time | |
import shutil | |
import os.path | |
import hashlib | |
import argparse |