Skip to content

Instantly share code, notes, and snippets.

View zhkuo24's full-sized avatar
🚩
learning

zhkuo zhkuo24

🚩
learning
  • University of Electronic Science and Technology of China
  • ChengDu Sichuan
View GitHub Profile
@zhkuo24
zhkuo24 / wiki.md
Last active August 29, 2015 14:07
用vim+vimwiki+GitHub构建个人wiki的过程

搭建个人wiki

  • 安装vim和vimwiki插件。
  • 首先安装vim。
  • 安装vimwiki插件。修改vimrc配置文件。
    {{{ set nocompatible filetype plugin on
    syntax on }}}
@zhkuo24
zhkuo24 / getimag.py
Last active June 14, 2016 15:48
从百度贴吧页面下载图片
# -*- coding: utf-8 -*-
import re #正则表达式库
import urllib.request
import urllib
import os
import pdb
def getHtml(url):
#req = urllib.request.Request(url)
page = urllib.request.urlopen(url)
html = page.read()
@zhkuo24
zhkuo24 / getweather.py
Last active August 29, 2015 14:18
获取天气预报信息
# -*- coding utf-8 -*-
# 获取天气预报信息
import urllib.request as request
import re
import pdb
def gethtml(url):
html = request.urlopen(url).read().decode()
return html
def getweather(html):
try: