This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# This script automatically sets the version and short version string of | |
# an Xcode project from the Git repository containing the project. | |
# | |
# To use this script in Xcode, add the contents to a "Run Script" build | |
# phase for your application target. | |
# NOTE: make sure you add a new value to your Info plist called "FullVersion" | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (NSString *)deviceIdentifier NS_AVAILABLE_IOS(8_0) { | |
UIScreen *screen = [UIScreen mainScreen]; | |
CGSize size = screen.nativeBounds.size; | |
CGFloat scale = screen.nativeScale; | |
NSString *identifier = [NSString stringWithFormat:@"w_%.00f_h_%.00f", size.width / scale , size.height / scale]; | |
return identifier; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Fastlane | |
module Actions | |
module SharedValues | |
DEVICES_LIST_CUSTOM_VALUE = :DEVICES_LIST_CUSTOM_VALUE | |
end | |
class ::String | |
def split_reject(pattern) | |
self.split(pattern).reject{|c|c.empty?} | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import UIKit | |
import ReactiveCocoa | |
protocol Bindable { | |
func bind<T>(viewModel: T) | |
} | |
class TableViewBinding<T, E: ErrorType> { | |
//MARK: Properties |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
public protocol Archivable { | |
typealias T | |
static func decompress(object: AnyObject) -> T? | |
static func compress(object: T) -> AnyObject | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fastlane_version "1.34.0" | |
before_all do | |
keys | |
end | |
desc "Sets up private keys" | |
private_lane :keys do | |
require 'cocoapods-core' | |
puts "Validating CocoaPods Keys" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'xcodeproj' | |
## PUBLIC INTERFACE ### | |
def project_name | |
'Moya' | |
end | |
def platforms | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
language = swift("3.0") | |
platforms = [ | |
macos("10.11"), | |
ios("8.0"), | |
tvos("9.0"), | |
watchos("2.0") | |
] | |
moya_tests = new_target do |target| | |
target.name = "MoyaTests" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
class Configuration | |
attr_accessor :installer_path | |
attr_accessor :patch_path | |
attr_accessor :instance | |
attr_accessor :site | |
attr_accessor :directory | |
attr_accessor :database_server | |
attr_accessor :database_name |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function moveCursorTo(node: Node, offset: number, native: Selection) { | |
// COMPAT: IE 11 does not support Selection.setBaseAndExtent, fallback to collapse | |
if (native.setBaseAndExtent) { | |
native.setBaseAndExtent(node, offset, node, offset); | |
} else { | |
native.collapse(node, offset); | |
} | |
} |