Skip to content

Instantly share code, notes, and snippets.

View bookiu's full-sized avatar
👨‍💻
Coding hard

yaxin bookiu

👨‍💻
Coding hard
View GitHub Profile
@bookiu
bookiu / dabblet.css
Created March 9, 2016 14:20
The first commented line is your dabblet’s title
/**
* The first commented line is your dabblet’s title
*/
background: #f06;
background: linear-gradient(45deg, #f06, yellow);
min-height: 100%;
@bookiu
bookiu / dabblet.css
Last active March 9, 2016 11:10
The first commented line is your dabblet’s title
/**
* The first commented line is your dabblet’s title
*/
body {
background: #f06;
background: linear-gradient(45deg, #f06, yellow);
min-height: 100%;
padding-top: 100px;
}
#site-header {
@bookiu
bookiu / README.md
Created January 7, 2016 09:13 — forked from magnetikonline/README.md
Nginx FastCGI cache configuration example.

Nginx FastCGI cache

Example /etc/nginx/nginx.conf using FastCGI (e.g. to PHP-FPM) with FastCGI cache enabled. This will capture returned data and persist it to a disk based cache store for a configurable amount of time, great for robust full page caching.

Will need to create a directory to hold cache files, for the example given here that would be:

$ sudo mkdir -p /var/cache/nginxfastcgi
$ chown www-data: /var/cache/nginxfastcgi
@bookiu
bookiu / 163-dl.php
Created October 22, 2015 06:07
网易云音乐MV 资源下载 - PHP
<?php
## Save as: 163-dl.php
// Musci Video - Format: http://localhost/163-dl.php?pv=720&id=313066
// Musci Singer - Format: http://localhost/163-dl.php?request=singer&id=313066
// Musci Name - Format: http://localhost/163-dl.php?request=name&id=313066
// Musci Cover - Format: http://localhost/163-dl.php?request=cover&id=313066
## Can append suffix to the link. Example: http://localhost/163-dl.php?pv=720&id=313066.mp4
## No Internal Error Output
ERROR_REPORTING(0);
@bookiu
bookiu / ffmpeg.md
Last active August 27, 2015 06:09 — forked from v5tech/ffmpeg.md
ffmpeg视频合并、格式转换、截图

使用ffmpeg合并MP4文件

ffmpeg -i "Apache Sqoop Tutorial Part 1.mp4" -c copy -bsf:v h264_mp4toannexb -f mpegts intermediate1.ts
ffmpeg -i "Apache Sqoop Tutorial Part 2.mp4" -c copy -bsf:v h264_mp4toannexb -f mpegts intermediate2.ts
ffmpeg -i "Apache Sqoop Tutorial Part 3.mp4" -c copy -bsf:v h264_mp4toannexb -f mpegts intermediate3.ts
ffmpeg -i "Apache Sqoop Tutorial Part 4.mp4" -c copy -bsf:v h264_mp4toannexb -f mpegts intermediate4.ts
ffmpeg -i "concat:intermediate1.ts|intermediate2.ts|intermediate3.ts|intermediate4.ts" -c copy -bsf:a aac_adtstoasc "Apache Sqoop Tutorial.mp4"
@bookiu
bookiu / docker2sshd_Dockerfile
Last active August 29, 2015 14:06
安装sshd的Dockerfile
# sshd
# VERSION 1.0.0
FROM ubuntu
MAINTAINER yaxin <yaxin.me@gmail.com>
# Set Server
# timezone and locale
RUN cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime;\
locale-gen zh_CN.UTF-8 en_US.UTF-8;\
@bookiu
bookiu / mwlist.txt
Last active August 29, 2015 14:06 — forked from hwdsl2/README.md
# This list summarizes malware caught in my Kippo SSH Honeypot (https://github.com/desaster/kippo/)
#
# For detailed instructions, please see:
# https://blog.ls20.com/check-your-server-for-malware-from-ssh-brute-force-attacks/
#
# Last Updated: September 3, 2014
#
# Copyright (C) 2014 Lin Song
#
# This program is free software: you can redistribute it and/or modify it under
@bookiu
bookiu / cookie.js
Created September 11, 2014 09:09
Javascript的cookie操作工具
@bookiu
bookiu / threading_ping.py
Created May 25, 2014 14:12
threading_ping.py
#/usr/bin/env python
#coding=utf-8
import Queue
import threading
import time
import ping
hosts = ['www.facebook.com','twitter.com', 'g.cn', 'baidu.com', 'z.cn', 'google.com', 'www.apple.com', 'www.youtube.com', 'www.blogspot.com']
@bookiu
bookiu / css_resources.md
Created April 22, 2014 10:37 — forked from jookyboi/css_resources.md
CSS libraries and guides to bring some order to the chaos.

Libraries

  • 960 Grid System - An effort to streamline web development workflow by providing commonly used dimensions, based on a width of 960 pixels. There are two variants: 12 and 16 columns, which can be used separately or in tandem.
  • Compass - Open source CSS Authoring Framework.
  • Bootstrap - Sleek, intuitive, and powerful mobile first front-end framework for faster and easier web development.
  • Font Awesome - The iconic font designed for Bootstrap.
  • Zurb Foundation - Framework for writing responsive web sites.
  • SASS - CSS extension language which allows variables, mixins and rules nesting.
  • Skeleton - Boilerplate for responsive, mobile-friendly development.

Guides