Skip to content
This repository has been archived by the owner on Sep 6, 2020. It is now read-only.

Releases: box-project/box2

Fixed Bootstrap Loading

27 Jan 03:59
Compare
Choose a tag to compare

Thanks to @TomasVotruba, bootstrap files are now actually loaded!

Friendly Improvements

03 Dec 23:39
Compare
Choose a tag to compare

You can now remove the shebang line!

{
    "shebang": false
}

Also, a new JavaScript minifier is bundled:

{
    "compactors": [
        "Herrera\\Box\\Compactor\\Javascript"
    ]
}

Yay!

Bug Fixes

27 Feb 17:47
Compare
Choose a tag to compare
  • 71938bf Fixes #75, where @git-version@ was not replaced in the output path.

Bug Fixes

09 Feb 19:58
Compare
Choose a tag to compare

Commits

  • 15a762f Changing branch reference.

Other

The dependencies have been updated to fix a bug when compacting annotated comments.

Bug Fixes

17 Jan 19:06
Compare
Choose a tag to compare

This is simply a bug fix release.

  • 68c8860 fixed test to run on mac os x (PHP_OS is set to „Darwin“ there)
  • bd59c0a Added custom error if error_get_last() does not return anything.

Annotations Supported

09 Nov 00:28
Compare
Choose a tag to compare

With the release of 2.4.0, I bring support for compacting Doctrine-styled annotations.

With the following configuration settings:

{
    "annotations": {
        "ignore": ["author"]
    },
    "compactors": [
        "Herrera\\Box\\Compactor\\Php"
    ]
}

This code:

<?php

/**
 * This is an example docblock with annotations.
 *
 * @author Kevin Herrera <[email protected]
 *
 * @ORM\Entity()
 * @ORM\Table(name="Test")
 */
class Test
{
}

Will be compacted to this:

<?php

/**
@ORM\Entity()
@ORM\Table(name="Test")




*/
class Test
{
}

I had to create a special library to handle this, so I recommend reading the documentation for herrera-io/php-annotations for more details about how the whole process works.

You can also find details about the configuration settings by running: box build -h

Phar-less Existance

23 Jul 22:09
Compare
Choose a tag to compare

This release makes use of new features in php-box v1.4.0:

  • Supports the StubGenerator->extract() method, which allows you to create phars that can still be executed without having the phar extension installed on the system. Just make sure your application or library can function without any of its features.
  • Supports limited functionality when the phar extension is not available. At the moment, you can only use the following commands in Box without a phar extension:
    • validate
    • verify
    • key:create
    • key:extract

You can find a complete change log here.

Mapping Paths

20 Jul 13:56
Compare
Choose a tag to compare

In this release, a new map setting has been added.

{
    "map": [
        { "path/to/match": "path/to/replace/with" },
        { "": "new/root/path/" }
    ]
}

As you can see, the setting is an array of objects. Each object is expected to have a single key/value pair, where the key is a path segment to match, and the value is the new segment to replace it with. Note that only relative paths, which begin with the path segment defined by the object key, will be matched.

Using the example above:

Before After
path/to/match/file.php path/to/replace/with/file.php
path/to/match/sub/file.php path/to/replace/with/sub/file.php
another/path/file.php new/root/path/another/path/file.php

An empty object key is a global match. However, instead performing path segment replacement, the value will be prefixed to the path that was matched. Don't forget to add a trailing slash for directory paths!

This could prove to be useful for Composer dependencies that have a target-dir set.

Thank you, @lyrixx, for the request!

1.0.9

23 Jul 22:54
Compare
Choose a tag to compare
Using explicit file paths.