 require 'shelljs/global'
 shout = require 'shout'
+logan = require 'logan'
 eco   = require 'eco'
+
+logan.set
+  info: ['%', 'green']
 
 # This module is the katon CLI.
 # It just creates/removes files, symlinks, etc...

    shout.rm "#{@launchAgentsPath}/katon.plist"

  installPow: ->
    console.log 'Installing Pow'
    shout.exec 'curl get.pow.cx | sh'

  # Creates a pow proxy and a symlink into katon path.
  link: (path = pwd())->
    name = path.split('/').pop()
    shout.to "#{@powPath}/#{name}", "4000"
    shout.mkdir "#{@katonPath}" unless test '-d', "#{@katonPath}"
    shout.exec "ln -s #{path} #{@katonPath}"
    logan.info "Application is now available at http://#{name}.dev"

  # Unlink:
  # Destroys what was created by link.
  unlink: (path = pwd()) ->
    name = path.split('/').pop()
    shout.rm '-f', "#{@powPath}/#{name}", "#{@katonPath}/#{name}"
    logan.info "Successfully removed #{name}"

  # Load:
  # Renders katon.plist.eco with the good env variables and
