Bug 1311255 - [RFE] rpmdev-packager check git configuration
Summary: [RFE] rpmdev-packager check git configuration
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: rpmdevtools
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Ville Skyttä
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-02-23 18:09 UTC by Carl George
Modified: 2016-06-28 18:20 UTC (History)
4 users (show)

Fixed In Version: rpmdevtools-8.9-1.fc24
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-06-28 18:09:38 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
enable rpmdev-packager to check git configuration (981 bytes, patch)
2016-02-23 18:09 UTC, Carl George
no flags Details | Diff
enable rpmdev-packager to check git configuration (983 bytes, patch)
2016-02-24 02:30 UTC, Carl George
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1350928 0 unspecified CLOSED [rpmdevtools] rpmdev-packager extracts full gecos field, not just full name 2021-02-22 00:41:40 UTC

Internal Links: 1350928

Description Carl George 2016-02-23 18:09:15 UTC
Created attachment 1129878 [details]
enable rpmdev-packager to check git configuration

Description of problem:
I would find it useful if the rpmdev-packager script check the git configuration for my username and email address.

How reproducible:
`git config user.name` and `git config user.email` contain all the necessary information for rpmdev-packager.

Additional info:
Patch attached.

Comment 1 Carl George 2016-02-24 02:30:35 UTC
Created attachment 1130006 [details]
enable rpmdev-packager to check git configuration

Whoops, forgot to wrap the email with < and >.

Comment 2 Ville Skyttä 2016-02-24 05:54:44 UTC
Yep, I noticed and fixed that and did some other modifications in
https://git.fedorahosted.org/cgit/rpmdevtools.git/commit/?id=769a09866ccacafa36b656caab07600f51ced722

In particular, I moved git to after .fedora.cert, because I guesstimate it's more likely for the git identity than the certificate one to be not the packager one.

Comment 3 Fedora Update System 2016-06-23 17:14:33 UTC
rpmdevtools-8.7-1.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2016-e11971c7e9

Comment 4 Fedora Update System 2016-06-23 17:16:01 UTC
rpmdevtools-8.7-1.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2016-9a18dce7e1

Comment 5 Fedora Update System 2016-06-25 00:27:49 UTC
rpmdevtools-8.7-1.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-9a18dce7e1

Comment 6 Fedora Update System 2016-06-25 00:32:22 UTC
rpmdevtools-8.7-1.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-e11971c7e9

Comment 7 Fedora Update System 2016-06-25 10:36:28 UTC
rpmdevtools-8.8-1.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2016-e11971c7e9

Comment 8 Fedora Update System 2016-06-25 10:37:40 UTC
rpmdevtools-8.8-1.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2016-9a18dce7e1

Comment 9 Fedora Update System 2016-06-26 00:27:38 UTC
rpmdevtools-8.9-1.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-e11971c7e9

Comment 10 Fedora Update System 2016-06-26 06:22:26 UTC
rpmdevtools-8.9-1.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-9a18dce7e1

Comment 11 Fedora Update System 2016-06-26 20:55:29 UTC
rpmdevtools-8.9-1.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report.

Comment 12 Fedora Update System 2016-06-27 22:56:24 UTC
rpmdevtools-8.9-1.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.

Comment 13 Carl George 2016-06-28 14:40:18 UTC
This isn't working right.  Moving the git configuration check after the packager certificates check revealed a bug in the latter that results in the git configuration not being used at all.

The fifth field of the passwd file can be used for more than just a name.  For example, if you use the chfn utility, it prompts you for the name, office, office phone, and home phone.  Even if you only set the name with that tool, it results in multiple commas in the $fullname as parsed by this script, such as:
John Doe,,,,

Given that plus an existing ~/.fedora.cert file, $packager is set to:
John Doe,,,, <john.doe>

Then the script never makes it to the git configuration check.

I'm not sure what the best course of action would be to correct this.  Improve the parsing of $fullname?  Move the git check back in front of the certificates check?

Comment 14 Ville Skyttä 2016-06-28 16:23:28 UTC
The issue looks completely unrelated to the git configuration check, so a separate bug report would have been preferable instead of reopening this... and due to the same reason, the root issue needs a real fix, not changing the order of the checks. That's done now in https://git.fedorahosted.org/cgit/rpmdevtools.git/commit/?id=b67dfbf0d1b88dbc722daf22ee27b18eb6244639

Comment 15 Carl George 2016-06-28 18:09:38 UTC
That's fair, sorry I didn't think of it like that initially.  I'll open a new BZ.


Note You need to log in before you can comment on or make changes to this bug.