   try
     towerPath = require.resolve('tower') # will fail on tower repo
   catch error
-    towerPath = _path.join(__dirname, '../../../index.js')
+    towerPath = _path.join(__dirname, '..#{_path.sep}..#{_path.sep}..#{_path.sep}index.js')
 
   grunt.registerMultiTask 'templates', 'Compile templates', ->
     name  = ""
     taskDone = @async()
     
-    files   = grunt.file.expand(['app/templates/**/*.coffee'])
+    files   = grunt.file.expand(['app#{_path.sep}templates#{_path.sep}**#{_path.sep}*.coffee'])
     result  = []
 
     pathSeparator = Tower.pathSeparator


      iterator = (remote, nextDownload) =>
        local = hash[remote]
        dir   = _path.resolve('./dist', _path.dirname(local))

        wrench.mkdirSyncRecursive(dir)

        agent.get(remote).end (response) =>
          #writeStream.write(response.text) if writeStream

          path = "./dist/#{local}"
          fs.writeFile path, response.text, =>
            process.nextTick nextDownload



      iterator = (remote, nextDownload) =>
        local = hash[remote]
        path = ".#{_path.sep}dist#{_path.sep}#{local}"
        grunt.helper 'upload2GitHub', path, local, nextUpload

      Tower.async keys, iterator, next
