commandbox-modules/commandbox-dotenv

check is not working as expected with custom examplesFileName

webmandman opened this issue · 0 comments

CommandBox Version: 5.1.1+00191 *
CommandBox Authors: Brad Wood, Luis Majano, Denny Valiant *
CommandBox Binary C:\Development\commandbox\box.exe *
CommandBox Home C:\Users\daniel.mejia.CommandBox *
CFML Engine: Lucee *
CFML Version: 5.3.6.61 stable (Gelert) *
Java Version: 11.0.6 (AdoptOpenJDK) *
Java Path: C:\Development\commandbox\jre\bin\java.exe *
OS Username daniel.mejia *
JLine Terminal org.jline.terminal.impl.jansi.win.JansiWinSysTerminal *
Runwar Version 4.1.0 (C:\Users\daniel.mejia.CommandBox\lib\runwar-4.1.0.jar)

commandbox-dotenv version: 2.1.10
propertyFile (1.2.0)

First, I tried > dotenv check with the default files names ".env" and ".env.examples". I didn't see that one key/value pair was missing in ".env" - it simply echoed "Check successful."

Then I renamed my examples file to ".env.tmpl" and used
> dotenv check envExampleFileName=.env.tmpl
this worked. It echoed: Missing keys detected from .env

but when I run:
> dotenv check
it echos: Check successful

so I thought i'd use config set:
config set modules.commandbox-dotenv.exampleFileName=.env.tmpl
then
> dotenv check
nothing. didn't work.

THE ONLY WAY i could get the check to work was by running:
dotenv check envExampleFileName=.env.tmpl
everytime. short format > dotenv check would be better.