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 | |
require 'xcodeproj' | |
require 'set' | |
project_file, target_name = ARGV | |
# open the project | |
project = Xcodeproj::Project.open(project_file) | |
# find the target |
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
/* | |
* Copyright (C) 2017 The Android Open Source Project | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software |
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
As of iOS 11/macOS High Sierra, and only including ones in Foundation and CoreFoundation | |
Strings: | |
_NSCFString - a CFStringRef or CFMutableStringRef. This is the most common type of string object currently. | |
- May have 8 bit (ASCII) or 16 bit (UTF-16) backing store | |
_NSCFConstantString - a compile time constant CFStringRef, like you'd get with @"foo" | |
- May also be generated by dynamic string creation if matches a string in a pre-baked table of common strings called the StringROM | |
NSBigMutableString - an NSString backed by a CFStorage (https://github.com/opensource-apple/CF/blob/master/CFStorage.h) for faster handling of very large strings | |
NSCheapMutableString - a very limited NSMutableString that allows for zero-copy initialization. Used in NSFileManager for temporarily wrapping stack buffers. |
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
for framework in $(find $SRCROOT/Carthage/Build/iOS/ -name "*.framework"); do | |
SCRIPT_INPUT_FILE_0=$framework SCRIPT_INPUT_FILE_COUNT=1 carthage copy-frameworks | |
done |
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 | |
protocol Observer { | |
var id: String { get } | |
func update(_ string: String) | |
} | |
extension Observer { | |
func update(_ string: String) { | |
print("\(type(of: self)) に届いた新しい値は \(string) です。") |
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
// ==UserScript== | |
// @name Discord WebM embed | |
// @description Embeds uploaded and linked WebM files | |
// @namespace Shou | |
// @include https://discordapp.com/channels/* | |
// @version 1 | |
// ==/UserScript== | |
var styleElem; |
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
// ==UserScript== | |
// @name kasi-time enabler | |
// @namespace http://example.com/ | |
// @version 0.2 | |
// @description | |
// @match http://www.kasi-time.com/* | |
// @copyright 2012+, You | |
// @downloadUrl https://gist.github.com/seangenabe/cc7cd26c791d16d244d7/raw/kasi-time.user.js | |
// @updateUrl https://gist.github.com/seangenabe/cc7cd26c791d16d244d7/raw/kasi-time.user.js | |
// ==/UserScript== |
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
# Android | |
gen/ | |
build/ | |
local.properties | |
# Old Android | |
bin/ | |
proguard/ | |
# suggestion: also ignore libs/*.properties files for old eclipse project | |
# can't be added here because multiple libs/ directory can be around in different paths |
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 | |
/// Protocol for NSLocking objects that also provide tryLock() | |
public protocol TryLockable: NSLocking { | |
func tryLock() -> Bool | |
} | |
// These Cocoa classes have tryLock() | |
extension NSLock: TryLockable {} | |
extension NSRecursiveLock: TryLockable {} |
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 bash | |
rm -rf "${HOME}/Library/Caches/CocoaPods" | |
rm -rf "`pwd`/Pods/" | |
pod update |
NewerOlder