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
// Match based on class | |
.shadow { | |
@horizontal: 1px; | |
@vertical: 2px; | |
@blur: 15px; | |
@spread: 2px; | |
@color: rgba(0,0,0,0.4); | |
box-shadow: @horizontal @vertical @blur @spread @color; | |
} |
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/Foundation.h> | |
#import <AppKit/AppKit.h> | |
int main(int argc, char *argv[]) { | |
@autoreleasepool { | |
NSPasteboard *pasteboard = [NSPasteboard generalPasteboard]; | |
NSLog(@"items: %@", pasteboard.pasteboardItems); | |
for (NSPasteboardItem *item in pasteboard.pasteboardItems) { | |
NSLog(@"types: %@", item.types); | |
for (NSString *type in item.types) { |
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
buttons = document.getElementsByTagName("button"); | |
for (key in buttons) { | |
button = buttons[key]; | |
attributes = button.attributes | |
if (attributes != undefined && attributes.getNamedItem('aria-label')) { | |
label = attributes.getNamedItem('aria-label') | |
value = String(label.value) | |
if (value == "Load more\n") { | |
console.log("clicking load more!"); | |
button.click(); |
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
// | |
// Async.swift | |
// | |
// Created by Tobias DM on 15/07/14. | |
// | |
// OS X 10.10+ and iOS 8.0+ | |
// Only use with ARC | |
// | |
// The MIT License (MIT) | |
// Copyright (c) 2014 Tobias Due Munk |
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 ObjectiveC.runtime; | |
@import MachO.dyld; | |
@import Foundation; | |
@interface IDELaunchParametersSnapshot : NSObject | |
+ (id)launchParametersWithSchemeIdentifier:(id)schemeIdentifier | |
launcherIdentifier:(id)launcherIdentifier | |
debuggerIdentifier:(id)debuggerIdentifier | |
launchStyle:(int)launchStyle | |
runnableLocation:(id)runnableLocation |
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
extension UITableView { | |
func registerCell<CellType: UITableViewCell>(type: CellType.Type) { | |
register(type, forCellReuseIdentifier: String(describing: type)) | |
} | |
func dequeueReusableCell<CellType: UITableViewCell>(for indexPath: IndexPath) -> CellType { | |
let identifier = String(describing: CellType.self) | |
let untypedCell = dequeueReusableCell(withIdentifier: identifier, for: indexPath) | |
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 subprocess | |
import os | |
def hook(hookfunc, oldfunc): | |
def foo(*args, **kwargs): | |
hookfunc(*args, **kwargs) | |
return oldfunc(*args, **kwargs) | |
return foo | |
def printFunction(*args, **kwargs): |
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
# from https://gist.github.com/cabeca/cbaacbeb6a1cc4683aa5 | |
#!/usr/bin/ruby | |
STDOUT.sync = true | |
device_types_output = `xcrun simctl list devicetypes` | |
device_types = device_types_output.scan /(.*) \((.*)\)/ | |
runtimes_output = `xcrun simctl list runtimes` | |
runtimes = runtimes_output.scan /(.*) \(.*\) \((com.apple[^)]+)\)$/ |
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
// | |
// Future+NilMap.swift | |
// Created on 3/10/19 | |
// | |
import Async | |
public protocol OptionalConstrainable { | |
associatedtype Element | |
var asOptional: Optional<Element> { get } |
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 python | |
import os | |
import sys | |
import os.path | |
import site | |
try: | |
import binaryninja | |
print "Binary Ninja API Installed" |
OlderNewer