$ cat test.js
function load(path)
{
console.warn("warning: %s not found", path);
return {};
}
require("yargs")
.config("config", load)
.global("config")
.command("command")
.argv;
$ node test --config /tmp/missing/file command
warning: /tmp/missing/file not found
warning: /tmp/missing/file not found
$