File tree Expand file tree Collapse file tree 1 file changed +0
-36
lines changed
Expand file tree Collapse file tree 1 file changed +0
-36
lines changed Original file line number Diff line number Diff line change @@ -91,42 +91,6 @@ echo $asset->getBody();
9191You can get the asset's last modified timestamp with the
9292` getLastModified ` method.
9393
94- ### Creating an Environment from a YAML File
95-
96- Pipe environments can also be created from YAML config files. First you
97- need an instance of ` Pipe\Config ` . Use the ` fromYaml ` static method to
98- parse an YAML file into a config instance.
99-
100- Use the config's ` createEnvironment ` method to convert a config to an
101- environment instance.
102-
103- ``` yaml
104- # pipe_config.yml
105- load_paths :
106- - assets
107- - vendor_assets
108-
109- my_custom_key : " foo bar"
110- ` ` `
111-
112- ` ` ` php
113- <?php
114-
115- use Pipe\Config;
116-
117- $config = Config::fromYaml("pipe_config.yml");
118- $env = $config->createEnvironment();
119- ```
120-
121- To retrieve a custom config key, access the "camelCased" name as
122- property:
123-
124- ``` php
125- <?php
126-
127- $key = $config->myCustomKey;
128- ```
129-
13094### Dumping an Asset to a File
13195
13296To dump an asset to a file, use the ` write ` method.
You can’t perform that action at this time.
0 commit comments