Skip to content

Instantly share code, notes, and snippets.

View glidenote's full-sized avatar

Akira Maeda glidenote

View GitHub Profile
@glidenote
glidenote / logmon.ini
Created December 1, 2011 02:52
logmon
#!/bin/sh
# chkconfig: 345 13 13
# description: Log Monitor
# processname: logmon
LOGMON_CONF=/etc/logmon/logmon.conf
LOGMON_BIN=/etc/logmon/logmon.pl
logmon_opts="-f $LOGMON_CONF"
@glidenote
glidenote / windowtidy.plist
Created December 7, 2011 13:34
windowtidy.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>KeepAlive</key>
<true/>
<key>Label</key>
<string>windowtidy</string>
<key>ProgramArguments</key>
<array>
@glidenote
glidenote / .tmux.conf
Created December 14, 2011 21:44
.tmux.conf
# status
set -g status-fg cyan
set -g status-bg black
set -g status-left-length 30
set -g status-left '#[fg=white,bg=black]#H#[fg=white]:#[fg=white][#S#[fg=white]][#[default]'
set -g status-right '#[fg=black,bg=cyan,bold] [%Y-%m-%d(%a) %H:%M]#[default]'
# window-status-current
setw -g window-status-current-fg black
@glidenote
glidenote / .zshenv
Created December 20, 2011 06:06
.zshenv
export PATH="$HOME/.rbenv/bin:$PATH"
eval "$(rbenv init -)"
source ~/.rbenv/completions/rbenv.zsh
@glidenote
glidenote / .vimrc
Created December 22, 2011 14:17
jekyll.vim.diff
Bundle "csexton/jekyll.vim"
let g:jekyll_path = "~/octopress/source/"
let g:jekyll_post_date = "%Y-%m-%d %H:%M"
let g:jekyll_post_published = "false"
let g:jekyll_prompt_categories = "true"
let g:jekyll_comments = "true"
map <Leader>jn :JekyllPost<CR>
map <Leader>jl :JekyllList<CR>
@glidenote
glidenote / allow_ip.sh
Created December 27, 2011 17:41
allow_ip.sh
#!/bin/sh
ALLOW_IP=`host hogehoge.com | awk '{print $4}'`
PORT_LIST="
22
80
443
3000
4000
@glidenote
glidenote / post.html.diff
Created January 3, 2012 09:39
related_posts
index d3c42e3..cd4c710 100644
--- a/source/_layouts/post.html
+++ b/source/_layouts/post.html
@@ -15,6 +15,9 @@ single: true
{% unless page.sharing == false %}
{% include post/sharing.html %}
@glidenote
glidenote / stone.diff
Created January 7, 2012 03:36
stone.diff
--- Makefile 2008-02-05 08:00:00.000000000 +0900
+++ Makefile 2009-08-19 08:59:00.000000000 +0900
@@ -97,7 +97,7 @@
$(MAKE) FLAGS="-DNT_SERVICE $(FLAGS)" LIBS="$(LIBS) $(SVC_LIBS) -ladvapi32 -luser32 -lshell32 -lkernel32" $(TARGET)
linux:
- $(MAKE) FLAGS="-O -Wall -DCPP='\"/usr/bin/cpp -traditional\"' -DPTHREAD -DUNIX_DAEMON -DPRCTL -DSO_ORIGINAL_DST=80 -DUSE_EPOLL $(FLAGS)" LIBS="-lpthread $(LIBS)" stone
+ $(MAKE) FLAGS="-O -Wall -DCPP='\"/usr/bin/cpp -traditional\"' -DPTHREAD -DUNIX_DAEMON -DPRCTL -DSO_ORIGINAL_DST=80 -DUSE_EPOLL -D_GNU_SOURCE $(FLAGS)" LIBS="-lpthread $(LIBS)" stone
linux-pop:
#! /bin/sh
#
# chkconfig: - 55 45
# description: The memcached daemon is a network memory cache service.
# processname: memcached
# config: /etc/sysconfig/memcached
# pidfile: /var/run/memcached/memcached.pid
# Standard LSB functions
#. /lib/lsb/init-functions
#compdef rudix
typeset -A opt_args
local context state line
_rudix() {
_arguments -s -S \
-h"[Show help message]" \
-v"[Print version]" \
-l"[List all installed packages (package-id, version and install date)]" \