#6651 dist-git: "Added the README" initial commits, can we get rid of them?
Closed: Upstream 7 years ago Opened 7 years ago by churchyard.

When a new src.fp.o repo is created, there is always a first commit. It used to be Initial setup of the repo with empty .gitignore and sources, now it appears to be Added the README by @limb.

Based on the official instructions, fedpkg import is used to get the spec + patches to git and sources to the lookaside cache. A call to fedpk import just removes such README. It have been there exactly one commit and it's gone.

A packager with more complex workflow might prep the package in git (on pagure, or github or whatever). Once the package is approved, the maintainer wishes to merge the git history from the preparatory place into Fedora master. However a merge commit with --allow-unrelated-histories has to be created because of the pointless initial README commit.

Is there a technical reason for the initial commit to be there when the repo is set up? Can we not do this? Or can we at least make it opt-out?


Metadata Update from @kevin:
- Issue tagged with: src.fp.o

7 years ago

However a merge commit with --allow-unrelated-histories has to be created because of the pointless initial README commit.

Well that was also required without the README, I believe creating the README was asked in purpose.

I'd also note that there is work in progress to try to make that README more useful (with some equivalent of badges in it).
So I'd be more in favor of asking fedpkg import to not delete the README file.

Is there a technical reason for the initial commit to be there when the repo is set up?

Yes, to create the master branch and thus make it easier for packagers new to git, they won't have to create the branch locally or specify it when they push.

Can we not do this? Or can we at least make it opt-out?

That would be an RFE on fedpkg (since fedrepo_req is now deprecated).

So there is a chain of things involved here:

fedpkg -> fedrepo_req -> fedrepo_req-admin

@churchyard can you file a RFE on fedpkg? if it added a switch to indicate you want no initial commits when it creates the request and I guess another one on fedrepo_req-admin to honor that request when processing that would do what you want?

Metadata Update from @kevin:
- Issue close_status updated to: Upstream
- Issue status updated to: Closed (was: Open)

7 years ago

Where is fedrepo_req-admin? https://pagure.io/fedrepo_req says deprecated.

I think it is still there, despite saying it's deprecated.

@churchyard fedrepo-req-admin is not deprecated though it's supported on a best effort basis right now. With that said, fedrepo-req and fedrepo-req-branch are deprecated and the deprecation warning is there because all those tools share the same repo. There's a backlog task somewhere to move fedrepo-req-admin to a separate repo. It's just not a priority for the Factory 2.0 team now.

Hello, there is a PR[1] for requesting a repo without initial commit. The request will contain a new item name initial_commit. So, when --no-initial-commit is specified to request-repo, "initial_commit": false is set in the ticket.

Is this enough for solving this issue? Or, is there anything to do?

[1] https://pagure.io/fedpkg/pull-request/240

For this issue, this has to be solved on the other hand too: https://pagure.io/fedrepo_req/issue/140

Log in to comment on this ticket.

Metadata