I have without success been trying to combine some of my mostly redundant Rake file tasks. Even directing me towards some documentation on rake rules would be great, I've found very little.
All examples I've found have been files that were distinguished by their extensions, in my case I need something more specific.
file '.../bundle-a.js' => ['a.js','b.js','c.js']
file '.../bundle-b.js' => ['d.js','e.js','f.js']
rule ??? => ??? do |f|
File.open( f.name, 'w' ) do |of|
of.write cat(f.prerequisites).concat('SPECIFIC TEXT TO EACH BUNDLE')
end
end
If I do a rule on .js => .js, I get recursive errors. If I look for /bundle/, it fails or I don't understand the processing that occurs. Also, I need to add that part about specific text, is there a solution via rules for this?