Skip to content

Instantly share code, notes, and snippets.

View louxiu's full-sized avatar
🏠
Working from home

louxiu louxiu

🏠
Working from home
View GitHub Profile
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@louxiu
louxiu / Client.java
Created March 15, 2017 11:11
Understanding netty channel buffers and watermarks
import io.netty.bootstrap.Bootstrap;
import io.netty.buffer.ByteBuf;
import io.netty.buffer.Unpooled;
import io.netty.channel.ChannelFuture;
import io.netty.channel.ChannelHandlerContext;
import io.netty.channel.ChannelInitializer;
import io.netty.channel.ChannelOption;
import io.netty.channel.ChannelPipeline;
import io.netty.channel.EventLoopGroup;
@louxiu
louxiu / rmmd-mode.el
Created October 25, 2012 10:07
rmmd-mode.el -- Major mode for editing README.md
;;; rmmd-mode.el -- Major mode for editing README.md
;; Author: louxiu <lou.0211@gmail.com>
;; Created: 25 10 2012
;; Keywords: RMMD major-mode
;; Copyright (C) 2012 louxiu <lou.0211@gmail.com>
;; This program is free software; you can redistribute it and/or
;; modify it under the terms of the GNU General Public License as
@louxiu
louxiu / ftp_new.sh
Created October 24, 2012 13:41
list new files(on specified directory) added on remote ftp server
#/bin/sh
get_files_list()
{
ftp_db="$1"
lftp ftp.hrbeu.edu.cn <<EOF
set ftp:charset GBK
@louxiu
louxiu / frame-tag-plus.el
Created October 22, 2012 11:18
Minor mode that assigns a unique number to each frame for easy switching
;; frame-tag-plus.el
;; Minor mode that assigns a unique number to each frame for easy switching
;; Date: Tue Oct 2 21:36:35 CST 2012
;; Author: louxiu lou.0211[at]gmail.com
;; frame-tag-plus base on frame-tag written by Wong Liang Zan zan[at]liangzan.net
;;; Usage: