Sha256: eadea0d571bbc858b00f3716ccba7140634ef5741168745f9cd32c5b29c0a3db
Contents?: true
Size: 718 Bytes
Versions: 4
Compression:
Stored size: 718 Bytes
Contents
require "bundler/gem_tasks" namespace :pousse do desc 'Precompile pousse.js' task :precompile do require './lib/pousse' require 'erb' require 'coffee-script' require 'uglifier' template = File.read(Pousse::TEMPLATE_SOURCE) token = "<%= token %>" iv = "<%= iv %>" server = "<%= server %>" script = CoffeeScript.compile(ERB.new(template, 0).result(binding)) script = script.gsub("\n", '') .gsub(" ", ' ') .gsub(" ", ' ') .gsub(" ", ' ') .gsub(" ", ' ') #TODO : Here we should use the next line with the right parameters. #script = Uglifier.compile(script) File.open(Pousse::TEMPLATE_MIN, 'w') { |file| file.write(script) } end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
pousse-0.0.6 | Rakefile |
pousse-0.0.5 | Rakefile |
pousse-0.0.4 | Rakefile |
pousse-0.0.3 | Rakefile |