Skip to content

Instantly share code, notes, and snippets.

View ZaidPathan's full-sized avatar

Mohammad Zaid Pathan ZaidPathan

View GitHub Profile
@ZaidPathan
ZaidPathan / Cartfile
Created March 24, 2019 16:21
TheAwesomeApp: Final Cartfile
github "ZaidPathan/Chat" "master"
github "ZaidPathan/Play" "master"
github "ZaidPathan/Pay" "master"
github "ZaidPathan/Shop" "master"
@ZaidPathan
ZaidPathan / Terminal
Created March 24, 2019 11:09
Carthage update
carthage update --platform iOS --cache-builds
@ZaidPathan
ZaidPathan / Cartfile
Created March 24, 2019 11:04
TheAwesomeApp: Cartfile for modules
github "ZaidPathan/Chat" "master"
touch Cartfile && open Cartfile
@ZaidPathan
ZaidPathan / Chat.swift
Last active March 24, 2019 10:31
TheAwesomeApp: Chat.swift file.
import Foundation
import UIKit
public class Chat {
public static let shared = Chat()
private let bundle = Bundle(for: Chat.self)
public func getViewController() -> UIViewController {
let storyboard: UIStoryboard = UIStoryboard(name: "ChatModule", bundle: bundle)
let viewController = storyboard.instantiateViewController(withIdentifier: "ChatViewController")
import UIKit
import AlamoWater
class ViewController: UIViewController {
override func viewDidLoad() {
super.viewDidLoad()
AlamoWater.shared.hello()
}
}
#!/bin/sh
UNIVERSAL_OUTPUTFOLDER=${BUILD_DIR}/${CONFIGURATION}-universal
# make sure the output directory exists
mkdir -p "${UNIVERSAL_OUTPUTFOLDER}"
# Step 1. Build Device and Simulator versions
xcodebuild -target "AlamoWater" ONLY_ACTIVE_ARCH=NO -configuration ${CONFIGURATION} -sdk iphoneos BUILD_DIR="${BUILD_DIR}" BUILD_ROOT="${BUILD_ROOT}" clean build
xcodebuild -target "AlamoWater" -configuration ${CONFIGURATION} -sdk iphonesimulator ONLY_ACTIVE_ARCH=NO BUILD_DIR="${BUILD_DIR}" BUILD_ROOT="${BUILD_ROOT}" clean build
import UIKit
public protocol AlamoWaterProtocol {
func didCallHello()
}
open class AlamoWater: NSObject {
public static let shared = AlamoWater()
public var delegate:AlamoWaterProtocol?
let leftExpression = NSExpression(forConstantValue: 999)
let rightExpression = NSExpression(forConstantValue: 1000)
let predicate = NSComparisonPredicate(leftExpression: leftExpression,
rightExpression: rightExpression,
modifier: NSComparisonPredicate.Modifier.direct,
type: NSComparisonPredicate.Operator.greaterThanOrEqualTo,
options: NSComparisonPredicate.Options.caseInsensitive)
options: NSComparisonPredicate.Options.caseInsensitive
)
@ZaidPathan
ZaidPathan / GIF-Screencast-OSX.md
Created January 24, 2017 07:21 — forked from dergachev/GIF-Screencast-OSX.md
OS X Screencast to animated GIF

OS X Screencast to animated GIF

This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.

Screencapture GIF

Instructions

To capture the video (filesize: 19MB), using the free "QuickTime Player" application: