Bug: Commit fails when no global email address is set even though --author is used

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



What did you do before the bug happened? (Steps to reproduce your issue)

* Set your machines hostname to a name that does not contain "." (e.g. "ihavenodotinmyhostname")
* Make sure you have no name or email configured in your global git config
* Create a new repository and "git add" a file
* Run: git commit -m "Test" --author "My Name <my@xxxxxxxxx>"

What did you expect to happen? (Expected behavior)

A commit should be created with author name "My Name", and author email "my@xxxxxxxxx"

What happened instead? (Actual behavior)

An error is thrown, complaining about not being able to determine the email address

What's different between what you expected and what actually happened?

The email should have been taken from the "--author" argument, but instead the commit failed.

Anything else you want to add:

This does not happen if your hostname contains a ".", e.g. "myhostname.local"

[System Info]
git version:
git version 2.40.1
cpu: x86_64
no commit associated with this build
sizeof-long: 8
sizeof-size_t: 8
shell-path: /bin/sh
uname: Linux 6.5.0-15-generic #15-Ubuntu SMP PREEMPT_DYNAMIC Tue Jan  9 17:03:36 UTC 2024 x86_64
compiler info: gnuc: 12.3
libc info: glibc: 2.38
$SHELL (typically, interactive shell): /bin/bash




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux