restechnica / semverbot

A CLI which automates semver versioning.
Mozilla Public License 2.0
136 stars 7 forks source link

git config debug logs have empty values when loading a config which does not define them #67

Open shiouen opened 8 months ago

shiouen commented 8 months ago
  1. Have a config file like:
mode = "auto"

[git]

#[git.config]
#email = "semverbot@github.com"
#name = "semverbot"

[git.tags]
prefix = "v"

[semver]
patch = ["fix", "bug"]
minor = ["feature"]
major = ["release"]

[modes]

[modes.git-branch]
delimiters = "/"

[modes.git-commit]
delimiters = "[]/"
  1. log output:
    12:44:19 DBG configuring git...
    12:44:19 DBG user.email=
    12:44:19 DBG user.name=

it is harmless, as exisiting git config would never be overwritten, but it is confusing. Would be good to make the logs more clear by showing already existing config values and configured values separately. e.g.

12:44:19 DBG configuring git...
12:44:19 DBG user.email from-git=email@email.com from-config=
12:44:19 DBG user.name from-git="Email Email" from-config=