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
### dotcloud 0.3.1 | |
# must be load .bash_completion (http://bash-completion.alioth.debian.org/) | |
# before load this file. | |
# expire_in filename expire_seconds | |
# expire_in foo.cache 300 # return true if go by 5min from last modification. | |
expire_in() { | |
local file=$1 | |
local expire=$2 |
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 os | |
import csv | |
from subprocess import Popen, PIPE | |
from Foundation import NSMutableDictionary | |
build_number = os.popen4("git rev-parse --short HEAD")[1].read() | |
info_plist = os.environ['BUILT_PRODUCTS_DIR'] + "/" + os.environ['WRAPPER_NAME'] + "/Info.plist" | |
# Open the plist and write the short commit hash as the bundle version | |
plist = NSMutableDictionary.dictionaryWithContentsOfFile_(info_plist) |
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 perl | |
use strict; | |
use warnings; | |
use Pod::Usage; | |
use Text::Markdown 'markdown'; | |
use HTML::TreeBuilder; | |
use List::Util 'max'; |
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
<?php | |
/** | |
* @author Benjamin Lazarecki <benjamin.lazarecki@gmail.com> | |
* Date: 07/06/12 | |
*/ | |
namespace Widop\Mink\Extension; | |
trait PopupDictionary |
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/sh | |
FrameworkName="MyKitName" | |
rm -rf ./Debug | |
mkdir ./Debug | |
cp -r ./Debug-iphoneos/${FrameworkName}.framework ./Debug/${FrameworkName}.framework | |
lipo -create ./Debug-iphoneos/${FrameworkName}.framework/${FrameworkName} ./Debug-iphonesimulator/${FrameworkName}.framework/${FrameworkName} -output ./Debug/${FrameworkName}.framework/${FrameworkName} |
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 | |
### | |
# | |
# Copyright (c) 2011 Cake Development Corporation (http://cakedc.com) | |
# | |
# Ubuntu 11.04 based web server installation script | |
# Run this by executing the following from a fresh install of Ubuntu 11.04 server: | |
# | |
# bash -c "$(curl -fsSL https://raw.github.com/gist/1264701)" <mysqlPassword> |
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 -x | |
# Description:PPTP for CentOS 6.4 64bit | |
# 2013/07/28 @ysaotome | |
( | |
### setting | |
/bin/cat << _SECRETS_ > /tmp/SECRETS_TMP.txt | |
#==============================================\n | |
# username auth_server password auth_ipaddress\n | |
"hoge001" "pptpd" "hoge##123" *\n |
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
/** | |
* NSNotificationのようなもの | |
* 通知で送る情報が詰まったオブジェクト | |
*/ | |
public class MyEventObject extends EventObject { | |
public static final String TAG = "MyEventObject"; | |
public enum EventType { | |
Hoge, |
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
<?php | |
function test($init, $key = 'a') | |
{ | |
$var = $init; | |
$var[$key] = 1; | |
echo var_export($init, true), ': ', is_array($var) ? 1 : 0, "\n"; | |
} | |
test(null); // OK |
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
/** | |
* natsort.js | |
* Sort an array using a "natural order" algorithm. | |
* | |
* @version 1.2.4 | |
* @author think49 | |
* @license http://www.opensource.org/licenses/mit-license.php (The MIT License) | |
* @url https://gist.github.com/660141 | |
* @see <a href="http://sourcefrog.net/projects/natsort/">Natural Order String Comparison</a> | |
*/ |
OlderNewer