How to make php-closure compiler output to a predefined file name? (Updated)

Posted by Mohammad on Stack Overflow See other posts from Stack Overflow or by Mohammad
Published on 2010-04-08T18:18:33Z Indexed on 2010/04/08 21:03 UTC
Read the original article Hit count: 391

Php-closure compiler (linked to source code) currently writes the compiled code to a md5 encoded filename. How can I make it so it write the compiled code to a predefined name like compiled_code.js?
.
.

I think it has to do with the write() function on Line 164. It gets the filename via the _getCacheFileName() function (Line 272).

  function _getCacheFileName() {
    return $this->_cache_dir . $this->_getHash() . ".js";
  }

I've tried altering it to this:

  function _getCacheFileName() {
    //return $this->_cache_dir . $this->_getHash() . ".js";
      return 'copiled_code.js';
  }

without any results.

Thanks to all of you in advance!

© Stack Overflow or respective owner

Related posts about php

Related posts about google-closure-compiler