Skip to content

Instantly share code, notes, and snippets.

@iamdionysus
iamdionysus / install.sh
Created November 6, 2015 15:10
install
#!/usr/bin/env bash
######################################################################
# Utility variable and function
######################################################################
GREEN='\033[0;32m'
NC='\033[0m' # No color
say()
@iamdionysus
iamdionysus / pull-all.sh
Last active February 8, 2016 04:23
git pull for all subdirectories
ls | xargs -I{} git -C {} pull
ls | xargs -P10 -I{} git -C {} pull
@iamdionysus
iamdionysus / insta-java-8.sh
Created November 30, 2016 02:49
Install java 8 and remove 7 in amazon linux
sudo yum install java-1.8.0 -y
sudo yum remove java-1.7.0-openjdk -y
@iamdionysus
iamdionysus / foo.scala
Created January 8, 2019 09:44
Scala: Pass Seq to var-args function
def foo(os: String*) = os.toList.foreach(println)
val args = Seq("hi", "there")
foo(args:_*)