- bigfix: removes tmpfile
-  introduces some subroutines
Signed-off-by: Sho Nakatani <lay.sakura@gmail.com>