- Fix JSTest data for cross-system compatibility;
- Update test-case for https://github.com/matthiasmullie/minify/issues/56 and perform fixes;
- Some code simplifications, remove some code duplicates;
- Ignore test samples for convenience of running tests;
- Update readme.
If we wait until after adjusting the paths relative to the new
target, we may fail to import them because the path they'll be
relative to may not yet exist.
If we do it after moving path
Previously the following error was thrown when passing `$data` over the filesystem file name limit:
```
file_exists(): File name is longer than the maximum allowed path length on this platform
```
Whenever an empty tag was found, everything before it risked
being eaten because I wasn't strict enough about the characters
allowed. Crossing `{` can not be allowed.
Fixes#67
Previous one didn't sufficiently remove double semicolons.
This one should be too eager, but then restore them if they
were valid in a for loop.
Fixes#70
Looks like webkit (especially Safari) doesn't properly handle
0% being 0.
Also had to rewrite some regexes because they should now assume
there may still be a unit.
Fixes issue #60
Previous commit of splitting into 2 regexes made no
sense. It seemed slightly faster in a small file, but
with large input, minification time almost doubled.
"return" looks like it could be a variable of which ['x']
is a key. I've improved the code to also check for keywords.
If whatever preceeds it is one of the keywords, don't convert.
Fixes issue #44
I had to split the action of minification into a separate
method because recursively importing files requires them
to also be minified, and I don't want that one to write
to a file.
I assumed it would be able to access the protected property
because we're in one from the same class, so it know the
business logic.
But we're in a closure which, in PHP5.3, doesn't inherit that
scope (which was exactly what I wanted to solve)
Let's just pass it the array, since I don't want to go making
that property public.