Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am syui on github.
  • I am syui (https://keybase.io/syui) on keybase.
  • I have a public key whose fingerprint is 1E8D B9FC 4B49 FA72 66A6 8426 8459 A733 DDFB 3B95

To claim this, I am signing this object:

<script src="http://ajax.googleapis.com/ajax/libs/jquery/2.2.4/jquery.min.js"></script>
<script src="../static/js/jquery.xdomainajax.js"></script>
<script src="../static/bower_components/d3/d3.min.js" charset="utf-8"></script>
<script src="../static/bower_components/cal-heatmap/cal-heatmap.min.js"></script>
<link rel="stylesheet" href="../static/bower_components/cal-heatmap/cal-heatmap.css" />
<!--<script src="https://raw.githubusercontent.com/syui/jquery.fn/master/cross-domain-ajax/jquery.xdomainajax.js"></script>-->
<!--diff : https://github.com/syui/jquery.fn/blob/master/cross-domain-ajax/jquery.xdomainajax.js#L62 -->
<h3>Calendar Activities</h3>
<div id="cal-heatmap"></div>
<div id="example-heatmap"></div>
@syui
syui / qiita-unfollow.sh
Created November 17, 2015 08:48
qiita-unfollow
#!/usr/local/bin/zsh
user=$USER
page=`curl -sL http://qiita.com/${user}/following_users | grep data-pjax | tail -n 1 | cut -d "?" -f 2 | cut -d '"' -f 1 | cut -d = -f 2`
#user=syui
#page=12
following=$(for (( i=1;i<=${page};i++ ))
do
html=`curl -sL "http://qiita.com/${user}/following_users?page=${i}" | grep 'span itemprop="name"' | tr '>' '\n' | grep -A1 'itemprop="name"' |cut -d '<' -f -1`
@syui
syui / comic-walker.com-screenshot.sh
Created November 17, 2015 08:47
comic-walker.com-screenshot.
#!/usr/local/bin/zsh
case $1 in
"") pg=16 ;;
*) pg=$1 ;;
esac
tl=`osascript -e 'tell application "Google Chrome" to get NAME of active tab of first window' | cut -d ' ' -f -1`
ul=`osascript -e 'tell application "Google Chrome" to get URL of active tab of first window'`
ul=`echo ${ul:t} | cut -d = -f 4-`
particlesJS("particles-js", {
"particles": {
"number": {
"value": 80,
"density": {
"enable": true,
"value_area": 800
}
},
"color": {
set -g status-fg white
set -g status-bg black
set -g pane-border-fg colour235
set -g pane-active-border-fg colour240
set -g prefix ^T
unbind C-b
unbind ^z
unbind !
unbind "\""
autoload -U compinit promptinit
compinit
zstyle ':completion:*:default' menu select=1
promptinit
prompt walters
alias up="pacman -Syu --noconfirm"
alias v="vim"
alias vs="v ~/.vimrc"
# export
export LANG=ja_JP.UTF-8
export PATH=$PATH:$HOME/.bin
export PLUGIN=$HOME/.zsh
export BUNDLE=$HOME/.vim/bundle
export GITHUB=https://github.com
export HISTFILE=~/.zsh_history
export HISTSIZE=20000
export SAVEHIST=20000
syntax enable
set number
set ruler
set list
set listchars=tab:>-,trail:-,nbsp:%,extends:>,precedes:<,eol:<
set incsearch
set hlsearch
set nowrap
set showmatch