I hereby claim:
- I am tvytlx on github.
- I am xiaotan (https://keybase.io/xiaotan) on keybase.
- I have a public key ASA7djdcbTYFzHHl4PnDKt9ZOFyf98HVNTcpTInbKEX5fgo
To claim this, I am signing this object:
f = (i)=>{ | |
return ()=>{return i;} | |
} | |
var a = [] | |
var b = [] | |
var c = [] | |
(()=>{ | |
for(var i=0; i<5; i++){ |
规范里用来声明 var/let 变量的内部方法是 CreateMutableBinding(),初始化变量用 InitializeBinding(),为变量赋值用 SetMutableBinding(), | |
引用一个变量用 GetBindingValue()。在执行完 CreateMutableBinding() 后没有执行 InitializeBinding() 就执行 SetMutableBinding() 或者 | |
GetBindingValue() 是会报错的,这种表现有个专门的术语(非规范术语)叫 TDZ(Temporal Dead Zone)。 | |
标准说用let和const初始化失败的变量将会永久的不能初始化了。 | |
let/const v = xx // xx is not defined | |
let/const v = 1 // v has already been declared | |
v = 1; let c = v // v is not defined |
class Property(object): | |
"Emulate PyProperty_Type() in Objects/descrobject.c" | |
def __init__(self, fget=None, fset=None, fdel=None, doc=None): | |
self.fget = fget | |
self.fset = fset | |
self.fdel = fdel | |
if doc is None and fget is not None: | |
doc = fget.__doc__ | |
self.__doc__ = doc |
// 便签元素在 frame 里,不能直接用 artoo 处理,得先得到内部的 dom 元素,然后传给 artoo。 | |
const iframe = 'iframe#js_note_mod_ctn.js_sandbox.business-mod-ctn.note-mod-ctn'; | |
let get_container = (str)=>{return $(iframe)[0].contentDocument.body.querySelector(str)}; | |
let notes_container = get_container('.home-bd .briefs-ctn.js_home_briefs_ctn'); | |
// 开始抓取 | |
let is_in_box = (this_)=>{ | |
return (this_.attr('class')=='js_folder_brief folder-brief js_normal_folder js_lock') || | |
(this_.attr('class')=='js_folder_brief folder-brief js_normal_folder') | |
}; |
I hereby claim:
To claim this, I am signing this object:
deb http://mirrors.163.com/ubuntu/ trusty main restricted universe multiverse | |
deb http://mirrors.163.com/ubuntu/ trusty-security main restricted universe multiverse | |
deb http://mirrors.163.com/ubuntu/ trusty-updates main restricted universe multiverse | |
deb http://mirrors.163.com/ubuntu/ trusty-proposed main restricted universe multiverse | |
deb http://mirrors.163.com/ubuntu/ trusty-backports main restricted universe multiverse | |
deb-src http://mirrors.163.com/ubuntu/ trusty main restricted universe multiverse | |
deb-src http://mirrors.163.com/ubuntu/ trusty-security main restricted universe multiverse | |
deb-src http://mirrors.163.com/ubuntu/ trusty-updates main restricted universe multiverse | |
deb-src http://mirrors.163.com/ubuntu/ trusty-proposed main restricted universe multiverse | |
deb-src http://mirrors.163.com/ubuntu/ trusty-backports main restricted universe multiverse |
The git plugin provides many aliases and a few useful functions.
Enable it by adding git to the plugins array before sourcing OMZ (see [[Plugins]]).
Alias | Command |
---|
#!/usr/bin/python | |
#-*- coding: utf-8 -*- | |
from __future__ import print_function, unicode_literals | |
import sys | |
import json | |
import os | |
import shutil | |
import re | |
import subprocess | |
import platform |
// First, open your github profile, then jump to repositories page. | |
// Second, copy this line to your browser's console. | |
r=[];$x('//a[@itemprop="name codeRepository"]/@href').forEach((x)=>{r.push(`git clone git@github.com:${x.value.slice(1)}.git`)});r.join('&&'); | |
// Third, copy the output which contains all the clone sentences to your terminal, then enter. |