Build: @netlify/config: don't error when --defaultConfig conflicts with config file on whether to use build.command or build.lifecycle.onBuild

Created on 17 Mar 2020  路  2Comments  路  Source: netlify/build

Describe the bug

netlify-config currently causes an error when a --defaultConfig with a build.command is passed in when the config file uses a build.lifecycle.onBuild.

Steps to reproduce

Run netlify-config --defaultConfig '{"build":{"command":"a-command"}}' in a folder that has a netlify.toml with the following contents:

[build.lifecycle]
onBuild = "a-different-command"

Expected behavior

The --defaultConfig option should never cause netlify-build to error out because it conflicts with the actual config file on how to specify the command.

bug

All 2 comments

Yes absolutely, that's an issue. I will fix that :+1:

Fixed in #981.

Was this page helpful?
0 / 5 - 0 ratings