-
Notifications
You must be signed in to change notification settings - Fork 51
Open
Description
Problem description
Running dotnet tool run versionize fails when extending Git config via includeIf in env vars.
Steps to reproduce
- Configure the env var
GIT_CONFIG_COUNT=1 - Configure the env var
GIT_CONFIG_KEY=include.path - Configure the env var
GIT_CONFIG_VALUE=D:\work\GitHub\dotfiles\.gitconfig - Create the Git config file
D:\work\GitHub\dotfiles\.gitconfigwith the following content:
[includeIf "gitdir:**/GitHub/"]
path = .gitconfig-github
- Create the Git config file
D:\work\GitHub\dotfiles\.gitconfig-githubwith the following content:
[user]
name = bla
email = [email protected]
- Create/clone a Git repository into
D:\work\GitHub\myRepo - Inside the cloned repo, run
git config user.emailand/orgit config user.nameand make sure that Git properly returns the configured value(s). - Make a change to the repository so that Versionize needs to create a new release.
- Run
dotnet tool run versionize
Expected Behavior
Versionize properly creates a release commit.
Actual Behavior
Warning: Git configuration is missing. Please configure git before running versionize:
git config --global user.name "John Doe"
$ git config --global user.email [email protected]
NativeCommandExitException: Program "dotnet.exe" ended with non-zero exit code: 1.
Workaround
Explicitly set the Git username and email address (although not necessary from Git perspective, only to make Versionize happy), i.e. duplicate the Git config.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels