Skip to content

Instantly share code, notes, and snippets.

@yannisxu
yannisxu / rmpsd
Last active August 29, 2015 14:00
删除某文件夹下指定后缀名的文件
find . -name "*.psd" | xargs rm -f
#删除某文件夹下指定后缀名的文件
# Quick and dirty demonstration of CVE-2014-0160 by Jared Stafford ([email protected])
# The author disclaims copyright to this source code.
import sys
import struct
import socket
import time
import select
import re
import codecs
# Quick and dirty demonstration of CVE-2014-0160 by Jared Stafford ([email protected])
# The author disclaims copyright to this source code.
import sys
import struct
import socket
import time
import select
import re
import codecs
#!/usr/bin/python
# Quick and dirty demonstration of CVE-2014-0160 by Jared Stafford ([email protected])
# The author disclaims copyright to this source code.
import sys
import struct
import socket
import time
import select
@yannisxu
yannisxu / index.html
Created November 21, 2013 19:22
HTML5 start code
<!DOCTYPE HTML>
<html>
<head>
<meta charset = "utf-8">
<title></title>
<link rel="stylesheet" href="style.css">
<script type="text/javascript" src="http://libs.baidu.com/jquery/1.9.0/jquery.js"></script>
<!--[if IE]><script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
<script scr ="script/script.js"></script>
Error in user YAML: (<unknown>): found character that cannot start any token while scanning for the next token at line 2 column 1
---
# Python 简介
@su27 and @menghan
---

What is Python?

Python: 优雅而健壮的编程语言

  • 高级

  • 易学易读易维护

@yannisxu
yannisxu / updatelocate.sh
Created August 6, 2013 04:02
mac 更新 locate
sudo /usr/libexec/locate.updatedb
@yannisxu
yannisxu / avoidsleep.sh
Created June 19, 2013 14:16
阻止mac进入睡眠状态
caffeinate -t 3600
@yannisxu
yannisxu / view-all-attr.py
Created May 13, 2013 07:33
python view all attr
for attr in dir(obj):
print "obj.%s = %s" % (attr, getattr(obj, attr))
@yannisxu
yannisxu / view_obj.js
Created May 13, 2013 06:45
view all javascript objects
jQuery.each(obj, function(name, value) {
console.log(name + ": " + value);
});