h1. Sublime Text 2 - Useful Shortcuts (Mac OS X)
h2. General
| ⌘T | go to file | | ⌘⌃P | go to project | | ⌘R | go to methods | | ⌃G | go to line | | ⌘KB | toggle side bar | | ⌘⇧P | command prompt |
#!/bin/bash | |
## | |
# start|stop|restart python SimpleHTTPServer | |
# | |
# TODO: | |
# use shell Function for DRY | |
# USAGE: | |
# ./manage_simplehttpserver.sh start|stop|restart | |
# |
#import <UIKit/UIKit.h> | |
#import <ImageIO/ImageIO.h> | |
#import <MobileCoreServices/MobileCoreServices.h> | |
- (void)exportAnimatedGif | |
{ | |
UIImage *shacho = [UIImage imageNamed:@"shacho.png"]; | |
UIImage *bucho = [UIImage imageNamed:@"bucho.jpeg"]; | |
NSString *path = [[NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) lastObject] stringByAppendingPathComponent:@"animated.gif"]; |
打开/前往 | |
⌘T 前往文件 | |
⌘⌃P 前往项目 | |
⌘R 前往 method | |
⌘⇧P 命令提示 | |
⌃G 前往行 | |
⌘KB 开关侧栏 | |
⌃ ` python 控制台 | |
⌘⇧N 新建窗口 |
h1. Sublime Text 2 - Useful Shortcuts (Mac OS X)
h2. General
| ⌘T | go to file | | ⌘⌃P | go to project | | ⌘R | go to methods | | ⌃G | go to line | | ⌘KB | toggle side bar | | ⌘⇧P | command prompt |
#!/bin/bash | |
# Interactive PoPToP install script on a OpenVZ VPS | |
# Tested on Debian 5, 6, and Ubuntu 11.04 | |
# 2011 v1.1 | |
# Author: Commander Waffles | |
# http://www.putdispenserhere.com/pptp-debian-ubuntu-openvz-setup-script/ | |
echo "######################################################" | |
echo "Interactive PoPToP Install Script for OpenVZ VPS" | |
echo "by Commander Waffles http://www.putdispenserhere.com" |
#!/bin/bash | |
function check_install { | |
if [ -z "`which "$1" 2>/dev/null`" ] | |
then | |
executable=$1 | |
shift | |
while [ -n "$1" ] | |
do | |
DEBIAN_FRONTEND=noninteractive apt-get -q -y install "$1" |
bottle | |
pymongo | |
mongoengine |
Pod::Spec.new do |s| | |
s.name = 'PlayHavenSDK' | |
s.version = '1.12.1' | |
s.license = 'MIT' | |
s.summary = 'PlayHaven is a real-time mobile game marketing platform to help you take control of the business of your games.' | |
s.homepage = 'http://playhaven.com' | |
s.author = { 'Sam Stewart' => '[email protected]' } | |
s.source = { :git => 'https://github.com/playhaven/sdk-ios.git', :tag => '1.12.1' } | |
s.description = "PlayHaven is a real-time mobile game marketing platform to help you take control of the business of your games. Acquire, retain, re-engage, and monetize your players with the help of PlayHaven's powerful marketing platform. Integrate once and embrace the flexibility of the web as you build, schedule, deploy, and analyze your in-game promotions and monetization in real-time through PlayHaven's easy-to-use, web-based dashboard. An API token and secret is required to use this SDK. These tokens uniquely identify your app to PlayHaven and prevent others from making requests to the API on you |
Pod::Spec.new do |s| | |
s.name = 'ChartboostSDK' | |
s.version = '3.1.1' | |
s.license = 'Commercial' | |
s.summary = 'ChartboostSDK for showing ads and more apps pages, and tracking analytics and in-app purchase revenue.' | |
s.homepage = 'https://chartboost.com/' | |
s.author = { 'Chartboost' => 'https://chartboost.com/' } | |
s.source = { :git => '~/Desktop/ChartboostSDK' } | |
s.platform = :ios | |
s.source_files = '**/*.h' |
NSString *UUID = [[NSUserDefaults standardUserDefaults] objectForKey:kApplicationUUIDKey]; | |
if (!UUID) { | |
CFUUIDRef uuid = CFUUIDCreate(NULL); | |
UUID = (__bridge_transfer NSString *)CFUUIDCreateString(NULL, uuid); | |
CFRelease(uuid); | |
[[NSUserDefaults standardUserDefaults] setObject:UUID forKey:kApplicationUUIDKey]; | |
[[NSUserDefaults standardUserDefaults] synchronize]; | |
} |