Re: git: 5386abd2502d - main - devel/forgejo-cli [New port]: CLI client for Forgejo

From: Joseph Mingrone <jrm_at_freebsd.org>
Date: Thu, 23 Apr 2026 17:20:54 UTC
On Thu, 2026-04-23 at 07:26, Mathieu Arnold <mat@freebsd.org> wrote:

> On Mon, Apr 20, 2026 at 09:35:57AM -0300, Joseph Mingrone wrote:
>> On Mon, 2026-04-20 at 07:10, Mathieu Arnold <mat@freebsd.org> wrote:

>> > On Sun, Apr 19, 2026 at 04:03:09PM -0300, Joseph Mingrone wrote:
>> >> On Sat, 2026-04-18 at 08:03, Daniel Engberg <diizzy@FreeBSD.org> wrote:

>> >> > On 2026-04-18 07:59, Joseph Mingrone wrote:
>> >> >> The branch main has been updated by jrm:

>> >> >> URL:https://cgit.FreeBSD.org/ports/commit/?id=5386abd2502d944ee3cf07b87b538a42f4c11980

>> >> >> commit 5386abd2502d944ee3cf07b87b538a42f4c11980
>> >> >> Author:     Joseph Mingrone<jrm@FreeBSD.org>
>> >> >> AuthorDate: 2026-04-17 19:49:12 +0000
>> >> >> Commit:     Joseph Mingrone<jrm@FreeBSD.org>
>> >> >> CommitDate: 2026-04-18 05:57:14 +0000

>> >> >> +++ b/devel/forgejo-cli/distinfo
>> >> >> @@ -0,0 +1,597 @@
>> >> >> +TIMESTAMP = 1776490248
>> >> >> +SHA256 (v0.5.0.tar.gz) = 028ebcbd744301fbfd144cd9bc5ff0a27e02d99b02c8abafb20742299715c556
>> >> >> +SIZE (v0.5.0.tar.gz) = 105814
>> >> > Hi, This is a no go... ^ Also, please check in tree how we fetch archives from codeberg (grep MASTER_SITES) Best regards, Daniel

>> >> Here is my attempt to make thing straightforward.  This is about 80% a
>> >> copy from USE_GITHUB and USE_GITLAB.

>> >> https://ron-dev.freebsd.org/FreeBSD/ports/pulls/9
>> >> https://ron-dev.freebsd.org/FreeBSD/doc/pulls/1

>> > I think what Daniel's email is missing was that you need to use
>> > something like DIST_SUBDIR=${PORTNAME} because the distfile is not
>> > specific to that port

>> With some grepping, I also noticed that it's possible to use a
>> MASTER_SITES URL such as:

>> https://codeberg.org/<account>/<project>/archive/${DISTVERSIONFULL}${EXTRACT_SUFX}?dummy=/

>> to get a distfile named, for example, forgejo-contrib-forgejo-cli-v0.5.0_FJ0.tar.gz.

> Yes, there are at least two quick ways to fix the port.

>> However, since we are already familiar with USE_GITHUB and USE_GITLAB, I thought

>> USE_FORGEJO=  yes
>> FJ_ACCOUNT=   forgejo-contrib

>> would be helpful.  The pull requests above give us this tooling and
>> documentation.

> This is another matter, and will probably take longer to commit than the
> two ways of fixing just this port.

I made a quick fix a few days ago, but only noticed yesterday that I
hadn't pushed it.  That fix is in 5386abd2502.

Side note: forgejo-cli (fj) works with the new ron-dev repositories, but
there are some rough edges.  Hopefully fj will become more useful as it
matures.

As for the USE_FORGEJO helpers, I've tested and tweaked
https://ron-dev.freebsd.org/FreeBSD/ports/pulls/9 and
https://ron-dev.freebsd.org/FreeBSD/doc/pulls/1, so they are ready for
anyone able to review.

fuz@ noted that since Forgejo is a fork of Gitea, these helpers may also
apply to Gitea.  I tested this by converting a port fetching from a
Gitea instance to USE_FORGEJO.  It worked, so I considered creating
USE_GITEA and GT_* aliases, but that's probably overkill.  Gitea doesn't
appear to be as widely used, at least in the ports tree, possibly
because it doesn't have a public instance like gitlab.com or
codeberg.org.  Documenting USE_FORGEJO compatibility with Gitea should
be sufficient for now.