一对一关系:有 A 和 B,A 拥有且仅拥有一个 B
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 python | |
# -*- coding: utf-8 -*- | |
import os | |
import struct | |
from mutagen.easyid3 import EasyID3 | |
def decode_gbk_from_unicode(s): | |
l, f = [], [] |
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
###### | |
# 本归档每周末收录当周的Tips | |
###### | |
# 以root身份执行上一条命令 | |
$ sudo!! | |
# 返回用户主目录 | |
$ cd |
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
265.com,2mdn.net,adnxs.com,adroll.com,adsonar.com,adtechus.com,aipai.com,atdmt.com,betrad.com,bluekai.com,cctv*.com,china.com,compete.com,douban.fm,etao.com,fantong.com,fastcdn.com,gamesville.com,google-analytics.com,harrenmedianetwork.com,homeinns.com,img.cctvpic.com,invitemedia.com,ipinyou.com,irs01.com,irs01.net,jing.fm,jysq.net,ku6cdn.com,kuaidi100.com ,legolas-media.com,live.com,lxdns.com,lycos.com ,lygo.com ,mangocity.com,mathtag.com,mediaplex.com,mediav.com,mlt01.com,mookie1.com,mosso.com,pixlr.com ,ptlogin2.qq.com,pubmatic.com,qstatic.com,quantserve.com,scanscout.com,scorecardresearch.com ,serving-sys.com ,sina.com,sinahk.net,sinajs.com ,snyu.com,staticsdo.com,sttlbb.com,tremormedia.com,tudouui.com,vizu.com,wrating.com ,xiu.com,yieldmanager.com,youshang.com, |
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/tclsh8.5 | |
# | |
# Usage: git-unmerged branch1 branch2 | |
# | |
# Shows all the non-common commits in the two branches, where non-common | |
# commits means simply commits with a unique commit *message*. | |
proc getlog branch { | |
lrange [split [exec git log $branch --oneline] "\n"] 0 400 | |
} |
Tencent (腾讯):
- http://isux.tencent.com/ (Internet Social User Experience/社交用户体验设计部)
- http://cdc.tencent.com/ (Customer Research & User Experience Design Center/即用户研究与体验设计中心)
- (已死) http://isd.tencent.com/ (Design Team for Internet Service Division/即用户研究与体验设计中心)
- (已死) http://wsd.tencent.com/
- (已死) http://flashteam.tencent.com/
- http://tgideas.qq.com/
- (已死) http://gdc.qq.com/
- (已死) http://ecd.tencent.com/
This installs a patched ruby 1.9.3-p327 with various performance improvements and a backported COW-friendly GC, all courtesy of funny-falcon.
You will also need a C Compiler. If you're on Linux, you probably already have one or know how to install one. On OS X, you should install XCode, and brew install autoconf
using homebrew.
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
#apple | |
#nslookup -vc a1.phobos.apple.com 168.95.1.1 | |
#203.78.36.42 203.69.138.18 | |
#jp 120.29.145.9 124.40.51.32 61.213.183.25 | |
address=/a1.mzstatic.com/203.69.138.18 | |
address=/a2.mzstatic.com/203.69.138.18 | |
address=/a3.mzstatic.com/203.69.138.18 | |
address=/a4.mzstatic.com/203.69.138.18 | |
address=/a5.mzstatic.com/203.69.138.18 | |
address=/a6.mzstatic.com/203.69.138.18 |
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
module Todo | |
class API < Grape::API | |
use Rack::Session::Cookie | |
version 'v1', :format => :json | |
helpers do | |
def current_user | |
return nil if env['rack.session'][:user_id].nil? | |
@current_user ||= User.get(env['rack.session'][:user_id]) | |
end |