Skip to content

Instantly share code, notes, and snippets.


Fatih Arslan fatih

View GitHub Profile
danp / goimports
Last active Sep 10, 2015
godep-aware goimports and more
View goimports
# for use with emacs/vim/etc as goimports and goflymake
# I use it with config like:
# (setenv "GOPATH" (expand-file-name "~/Projects/go"))
# (setenv "PATH" "~/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:~/Projects/go/bin:/usr/local/go/bin")
# (setq exec-path (append exec-path (list (expand-file-name "~/Projects/go/bin") "/usr/local/go/bin")))
jonhoo /
Last active Oct 22, 2018
Distributed RWMutex in Go
kachayev /
Last active Apr 18, 2021
Channels Are Not Enough or Why Pipelining Is Not That Easy
guelfey / cover.vim
Created Aug 16, 2013
Vim plugin for Go test coverage profiles
View cover.vim
" cover.vim - Vim plugin for Go test coverage profiles
" install in ftplugin/go
" ":Cover coverprofile" will open the current file in a new read-only window,
" highlighting the code regarding to whether it is covered by tests or not.
" You can change the colors by highlighting goTestCovered and goTestNotCovered
" from your vimrc.
if exists("b:did_ftplugin_go_cover")
import os
import sys
import threading
import zmq
def worker(identity, wurl):
ctx = zmq.Context.instance()
s = ctx.socket(zmq.REP)
s.identity = identity
View slide10.go
func worker(die chan bool) {
for {
select {
// ... do stuff cases
case <- die:
michaelglass / Coffeescript ctags
Last active Dec 15, 2015 — forked from Gonzih/Coffeescript ctags
allow for default assignment in constructor
View Coffeescript ctags
--regex-coffee=/(^|=[ \t])*class ([A-Za-z]+\.)*([A-Za-z]+)( extends [A-Za-z_.]+)?$/\3/c,class/
--regex-coffee=/^[ \t]*(module\.)?(exports\.)?@?([A-Za-z_.]+):.*[-=]>.*$/\3/m,method/
--regex-coffee=/^[ \t]*(module\.)?(exports\.)?([A-Za-z_.]+)[ \t]+=.*[-=]>.*$/\3/f,function/
--regex-coffee=/^[ \t]*([A-Za-z_.]+)[ \t]+=[^->\n]*$/\1/v,variable/
--regex-coffee=/^[ \t]*@([A-Za-z_.]+)[ \t]+=[^->\n]*$/\1/f,field/
--regex-coffee=/^[ \t]*@([A-Za-z_.]+):[^->\n]*$/\1/f,static field/
--regex-coffee=/^[ \t]*([A-Za-z_.]+):[^->\n]*$/\1/f,field/
anandkunal / simple_reverse_proxy.go
Created Sep 4, 2012
Simple reverse proxy in Go.
View simple_reverse_proxy.go
package main
import (
func main() {
dreamiurg /
Created Jul 25, 2011 for webfaction and vagrant
This fabric file makes setting up and deploying a django application much
easier to webfaction servers or your dedicated server, but it does make a
few assumptions. Namely that you're using Git, Apache and mod_wsgi. Also
you should have SSH installed on both the local machine and any servers you
want to deploy to.
Thanks to:
elazarl / redcon.go
Created Jun 6, 2011
redirect network stream
View redcon.go
package main
import (