 fs = require "fs"
 path = require "path"
 crypto = require 'crypto'
+path = require "path"
 
 _ = require "underscore"
 async = require "async"


      pile = @piles[asset.name]

      # Wrong asset type. Lets skip to next middleware.
      if asset.ext isnt pile.ext
        return next()

      if not pile
        res.send "Cannot find pile #{ pileName }"
        return

      if asset.min
        res.end pile.rawPile

    @rawPile = null
    @urls = []
    @devMapping = {}
    @piledUp = false

  addFile: (filePath) ->
    filePath = path.normalize filePath
    @warnPiledUp "addFile"
    if filePath not in @getFilePaths()
      @code.push asCodeOb.call
        type: "file"
