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 | |
#===================== | |
while : | |
do | |
echo "Current DIR is " $PWD | |
stillRunning=$(ps -ef |grep "/data/wwwroot/lottery_v2/CORE/think auto" |grep -v "grep") | |
if [ "$stillRunning" ] ; then | |
echo "running..." | |
else | |
echo "restart ..." |
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 gm | |
function get_fenci($word) { | |
$word = preg_replace('/\s+/', ' ', trim($word)); | |
$word_arr = explode(' ', $word); | |
$segments = array(); | |
foreach ($word_arr as $word) { |
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
实时的分布式sphinx索引配置及使用方法总结 coreseek文档:http://sphinxsearch.com/wiki/doku.php?id=sphinx_manual_chinese#需要的工具 需要更改/usr/local/coreseek/var/data 下的目录权限 | |
安装开始: | |
cd /data/softwore | |
wget http://www.coreseek.cn/uploads/csft/4.0/coreseek-4.1-beta.tar.gz(只安装中文分词mmseg3) | |
tar zxvf coreseek-4.1-beta.tar.gz | |
cd coreseek-4.1-beta.tar.gz/ | |
安装mmseg | |
$ cd mmseg-3.2.14 //根据具体的版本而定 | |
$ ./bootstrap #输出的warning信息可以忽略,如果出现error则需要解决 |
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
javascript: (function () { | |
function c() { | |
var e = document.createElement("link"); | |
e.setAttribute("type", "text/css"); | |
e.setAttribute("rel", "stylesheet"); | |
e.setAttribute("href", f); | |
e.setAttribute("class", l); | |
document.body.appendChild(e) | |
} | |
function h() { |
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 | |
# Sometimes you need to move your existing git repository | |
# to a new remote repository (/new remote origin). | |
# Here are a simple and quick steps that does exactly this. | |
# | |
# Let's assume we call "old repo" the repository you wish | |
# to move, and "new repo" the one you wish to move to. | |
# | |
### Step 1. Make sure you have a local copy of all "old repo" | |
### branches and tags. |
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 | |
# Sometimes you need to move your existing git repository | |
# to a new remote repository (/new remote origin). | |
# Here are a simple and quick steps that does exactly this. | |
# | |
# Let's assume we call "old repo" the repository you wish | |
# to move, and "new repo" the one you wish to move to. | |
# | |
### Step 1. Make sure you have a local copy of all "old repo" | |
### branches and tags. |
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
<!doctype html> | |
<title>Site Maintenance</title> | |
<style> | |
body { text-align: center; padding: 150px; } | |
h1 { font-size: 50px; } | |
body { font: 20px Helvetica, sans-serif; color: #333; } | |
article { display: block; text-align: left; width: 650px; margin: 0 auto; } | |
a { color: #dc8100; text-decoration: none; } | |
a:hover { color: #333; text-decoration: none; } | |
</style> |
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
/* | |
* object.watch polyfill | |
* | |
* 2012-04-03 | |
* | |
* By Eli Grey, http://eligrey.com | |
* Public Domain. | |
* NO WARRANTY EXPRESSED OR IMPLIED. USE AT YOUR OWN RISK. | |
*/ |
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
/* | |
:: Enhanced Version @extralam :: | |
Allows for ajax requests to be run synchronously in a queue , remove queue | |
Usage:: | |
var queue = new $.AjaxQueue(); | |
// add with tag name or not , both ok | |
queue.add('test',{ | |
url: 'url', |
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
set nocompatible " be iMproved, required | |
filetype off " required | |
" set the runtime path to include Vundle and initialize | |
set rtp+=~/.vim/bundle/Vundle.vim | |
call vundle#begin() | |
" alternatively, pass a path where Vundle should install plugins | |
"call vundle#begin('~/some/path/here') | |
" let Vundle manage Vundle, required |
NewerOlder