Custom #config paths


#1

I discovered, that it’s possible to create custom config paths inside addons with $app->path('#config', __DIR__.'/config');. I tried it in the FormValidation Addon and the ouput of print_r($app) tells me

[paths:protected] => Array (
    // ...
    [#config] => Array (
            [0] => E:/path/to/cockpit/addons/FormValidation/config/
            [1] => E:/path/to/cockpit/config/
        )

Loading custom mail templates from the addon config path works fine and the configuration from cockpit #config loads correctly. But writing files (from cli) to #config, e. g. ./cp create-lang --lang de writes the files to the wrong directory now.

The idea for the custom config paths came from

Did I misunderstand the concept?