1.0.2
This commit is contained in:
parent
c8eac16ffc
commit
c9f8cafa56
3 changed files with 24 additions and 19 deletions
|
@ -1,6 +1,6 @@
|
||||||
# Angel Configuration
|
# Angel Configuration
|
||||||
|
|
||||||

|

|
||||||

|

|
||||||
|
|
||||||
Isomorphic YAML configuration loader for Angel.
|
Isomorphic YAML configuration loader for Angel.
|
||||||
|
@ -17,7 +17,7 @@ In `pubspec.yaml`:
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
dependencies:
|
dependencies:
|
||||||
angel_configuration: ^1.0.0-dev
|
angel_configuration: ^1.0.0
|
||||||
```
|
```
|
||||||
|
|
||||||
# Usage
|
# Usage
|
||||||
|
|
|
@ -14,6 +14,7 @@ class ConfigurationTransformer extends Transformer {
|
||||||
ConfigurationTransformer.asPlugin(this._settings) {}
|
ConfigurationTransformer.asPlugin(this._settings) {}
|
||||||
|
|
||||||
Future apply(Transform transform) async {
|
Future apply(Transform transform) async {
|
||||||
|
try {
|
||||||
var app = new Angel();
|
var app = new Angel();
|
||||||
|
|
||||||
await app.configure(loadConfigurationFile(
|
await app.configure(loadConfigurationFile(
|
||||||
|
@ -29,7 +30,11 @@ class ConfigurationTransformer extends Transformer {
|
||||||
text = text.replaceAll(replaced["needle"], replaced["with"]);
|
text = text.replaceAll(replaced["needle"], replaced["with"]);
|
||||||
}
|
}
|
||||||
|
|
||||||
transform.addOutput(new Asset.fromString(transform.primaryInput.id, text));
|
transform
|
||||||
|
.addOutput(new Asset.fromString(transform.primaryInput.id, text));
|
||||||
|
} catch (e) {
|
||||||
|
// Fail silently...
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
name: angel_configuration
|
name: angel_configuration
|
||||||
description: Isomorphic YAML configuration loader for Angel.
|
description: Isomorphic YAML configuration loader for Angel.
|
||||||
version: 1.0.1+8
|
version: 1.0.2
|
||||||
author: Tobe O <thosakwe@gmail.com>
|
author: Tobe O <thosakwe@gmail.com>
|
||||||
homepage: https://github.com/angel-dart/angel_configuration
|
homepage: https://github.com/angel-dart/angel_configuration
|
||||||
dependencies:
|
dependencies:
|
||||||
|
|
Loading…
Reference in a new issue