Skip to content

Instantly share code, notes, and snippets.

@si1en2i0
si1en2i0 / gist:2191635
Created March 25, 2012 05:59
简易滚动列表
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8" />
<style type="text/css">
* { margin:0; padding:0; }
li { font-size:12px; height: 1.5em;}
</style>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.js"></script>
@si1en2i0
si1en2i0 / extract_zip_in_correct_encoding.php
Created June 11, 2012 08:54
Linux/MacOS下解压中文乱码的zip包
<?php
/**
* 解压含有文件名为UTF-8编码的zip包,到当前目录
*
* Mac OS X 系统自带的压缩程序对 zip 文件名用 UTF-8 编码
* 但 zip 文件头中没有声明 PKZIP 高版本增加的 Unicode 位。
* Windows 会认为文件名是 ANSI 编码,结果显示乱码。
*
* @uses zipcorrect.php file.zip
@si1en2i0
si1en2i0 / package.rb
Created June 11, 2012 08:58
根据yaml文件的内容打包指定的文件
#!/usr/bin/env ruby
#coding: utf-8
require 'yaml'
require 'fileutils'
config_file_path = 'package.yaml'
# get related diretories information & prepare
src = Dir.getwd
@si1en2i0
si1en2i0 / git_guidline.md
Created October 16, 2012 06:02 — forked from onlytiancai/git_guidline.md
git分支使用规范

分支管理

最少有三个长期分支

  • master: 用于生产环境部署
  • testing: 用于测试环境测试
  • dev: 用于日常开发

有一些临时分支

<?php
/**
* SplClassLoader implementation that implements the technical interoperability
* standards for PHP 5.3 namespaces and class names.
*
* http://groups.google.com/group/php-standards/web/final-proposal
*
* // Example which loads classes for the Doctrine Common package in the
* // Doctrine\Common namespace.
Pod::Spec.new do |s|
s.name = 'JSONKit'
s.version = '1.6'
s.summary = 'A Very High Performance Objective-C JSON Library.'
s.homepage = 'https://github.com/johnezang/JSONKit'
s.author = 'John Engelhart'
s.source = { :git => 'https://github.com/HerrEmrys/JSONKit' }
s.source_files = 'JSONKit.*'
end