Skip to content

Instantly share code, notes, and snippets.

@JosephKu
JosephKu / .profile
Last active September 13, 2016 15:20
Bash profile file for Mac OS X
# .profile for Bash on Mac OS X
#
# Written by Joseph Ku <chiehfang.ku@gmail.com>
# All right reserved.
# 'ls' with colors
export CLICOLOR=1
#export LSCOLORS=gxBxhxDxfxhxhxhxhxcxcx
#export LSCOLORS=ExxxxxDxBxegedabxxacad
export LSCOLORS=ExFxCxDxBxegedabagacad
@JosephKu
JosephKu / vim.rb
Created August 8, 2011 14:20
Vim formula for HomeBrew
#/usr/local/Library/Formula/vim.rb
#
# Vim formula for HomeBrew
#
# Written by Joseph Ku <chiehfang.ku@gmail.com>
# All right reserved.
require 'formula'
class Vim < Formula
@JosephKu
JosephKu / image_uploading_test.rb
Created August 11, 2011 09:36
Image uploading test tool
#!/usr/bin/env ruby
# image_uploading_test.rb
#
# Written by Joseph Ku <chiehfang.ku@gmail.com>
# All right reserved.
require 'rmagick'
require 'rest_client'
@JosephKu
JosephKu / .gitignore_global
Created September 7, 2011 03:28
Global .gitignore file
#########
# Linux #
#########
.*
!.gitignore
*~
# KDE
.directory
@JosephKu
JosephKu / bash-completion.rb
Created January 30, 2012 05:23
Bash-completion formula for HomeBrew
require 'formula'
class BashCompletion < Formula
url 'http://pkgs.fedoraproject.org/repo/pkgs/bash-completion/bash-completion-1.3.tar.bz2/a1262659b4bbf44dc9e59d034de505ec/bash-completion-1.3.tar.bz2'
homepage 'http://bash-completion.alioth.debian.org/'
md5 'a1262659b4bbf44dc9e59d034de505ec'
head 'git://git.debian.org/git/bash-completion/bash-completion.git'
def install
inreplace "bash_completion" do |s|
@JosephKu
JosephKu / vimrc
Last active November 4, 2016 19:44
Vimrc
" vim-plug
fun! EnsureVimPlugIsOnDisk(vimplug_install_path)
if !filereadable(a:vimplug_install_path.'/plug.vim')
\&& 1 == confirm("Install vim-plug into ".a:vimplug_install_path."?","&Y\n&N")
execute '!curl -fLo '.a:vimplug_install_path.'/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
endif
endfun
fun! SetupVimPlug()
let vimplug_install_path = expand('$HOME').'/.vim/autoload'
@JosephKu
JosephKu / README.md
Last active February 3, 2022 05:16
Street Fighter x Mega Man for Mac

STREET FIGHTER® X MEGA MAN® for Mac

STORY

Having fought countless robot masters over the years, Mega Man is ready to lay back, relax and enjoy his 25th Anniversary. Getting wind of this, Ryu and his fellow Street Fighters want one last battle before they let their own anniversary finish. Charge up your mega busters and stretch out your lightning legs, this is Street Fighter® X Mega Man®!

require 'formula'
class Despotify < Formula
head 'https://svn.code.sf.net/p/despotify/code/src'
homepage 'http://despotify.se/'
depends_on 'pkg-config' => :build
depends_on 'libao'
depends_on 'libvorbis'
depends_on 'mpg123'
@JosephKu
JosephKu / nginx
Created November 10, 2014 09:33
Nginx Ubuntu/Debian init script
#!/bin/sh
### BEGIN INIT INFO
# Provides: nginx
# Required-Start: $all
# Required-Stop: $all
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: starts the nginx web server
# Description: starts nginx using start-stop-daemon
Verifying that +josephku is my openname (Bitcoin username). https://onename.io/josephku