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 | |
// @ operator | |
// compare to circle | |
$conditions = array( | |
'loc @' => array('circle' => array('point'=> array(10.1,10.1), 100)), | |
); | |
// order by distance | |
$order = array( | |
'loc <-> point(10.1,10.1)' | |
); |
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 | |
export CAKEPHP_VERSION=2.0.5 | |
export CAKEPHP_PATH=/usr/local/app | |
if [ ! -d $CAKEPHP_PATH ] | |
then | |
mkdir $CAKEPHP_PATH | |
fi | |
# IPアドレスを取得 |
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 | |
export BASERCMS_PATH=/usr/local/app | |
if [ ! -d $BASERCMS_PATH ] | |
then | |
mkdir $BASERCMS_PATH | |
fi | |
# IPアドレスを取得 | |
export IPADDR=`ip addr show | grep eth0 | grep 'inet *' | awk '{print $2;}' | cut -f1 -d '/'` |
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 | |
# apache,fluent-plugin-s2が依存するパッケージをインストール | |
yum -y install httpd.x86_64 \ | |
libxml2-devel.x86_64 libxslt-devel.x86_64 | |
# td-agent 用のリポジトリを登録 | |
cat <<_EOT_ 1>/etc/yum.repos.d/td.repo | |
[treasuredata] | |
name=TreasureData |
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
#!bash | |
# | |
# bash completion support for core Git. | |
# | |
# Copyright (C) 2006,2007 Shawn O. Pearce <spearce@spearce.org> | |
# Conceptually based on gitcompletion (http://gitweb.hawaga.org.uk/). | |
# Distributed under the GNU General Public License, version 2.0. | |
# | |
# The contained completion routines provide support for completing: | |
# |
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 | |
/** | |
* Encrypt behavior | |
* | |
*/ | |
class EncryptBehavior extends ModelBehavior { | |
// Encryption settings | |
const CIPHER = MCRYPT_RIJNDAEL_128; | |
const MODE = MCRYPT_MODE_CBC; |
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
// | |
// MyTestSegue.m | |
// StoryBoardTest | |
// | |
#import "MyTestSegue.h" | |
@implementation MyTestSegue | |
- (void)perform |
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
location / { | |
index index.php index.html index.htm; | |
if (!-e $request_filename) { | |
rewrite ^(.*)$ /index.php?url=$1 last; | |
break; | |
} | |
} | |
location ~ .php(/|$) { | |
fastcgi_split_path_info ^(.+\.php)(.*)$; |
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 | |
// 大分やっつけ感がある感じ...orz | |
class CoMeeting { | |
private $url = 'https://www.co-meeting.com'; | |
private $cookie = null; | |
private $params = null; | |
public function __construct($config='config.php') | |
{ | |
include($config); |
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 | |
// 大分やっつけ感がある感じ...orz | |
class CoMeeting { | |
private $url = 'https://www.co-meeting.com'; | |
private $cookie = null; | |
private $params = null; | |
public function __construct($config='config.php') | |
{ | |
include($config); |