[Top][All Lists]

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

Sourcehut packaging in 2023

From: Thomas Ieong
Subject: Sourcehut packaging in 2023
Date: Mon, 06 Mar 2023 09:48:03 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux)


This mail is there to give an overview of what packages are we missing
and how to build a sourcehut service.

A sourcehut service is a mix of python/golang/js and static

Python: We have almost everything except 2 packages, python-pam and
another one that I forgot.

Js: It's actually alright, the js that are there are standalone, no
npm nightmare, there was minify a npm package, but Mr.Devault replaced
it by a golang package with the same name.

Golang: This is where the pain is at, a lot of them are missing
we will need to package ~sircmpwn/core-go this contains a lot of
golang code shared by all services.

Now a short guide on how to build a sourcehut service.


    I'm focusing on this service first because it is needed
    by all other services.

    It contains python dependencies, icons/js/scss and static assets.

    It also has bootstrap as a git submodule, now the good news is that
    we don't need to package the entirety of bootstrap, basically it
    only needs the scss directory of bootstrap.

    In order to build you will need to run

    Note that (this apply to all services) it will call git
    to get which version it is on, so we probably need to patch that.

    It will package the srht folder containing the aforementioned
    dependencies and a Makefile.

    This Makefile is very important as it will be included in the
    Makefile of all other services, so that they can build their static

    - *

    Now the generic build method for all other sourcehut services.

    You run in the root directory, it contains a call to a
    Makefile in that same directory and this Makefile will include the
    Makefile from so that it can build its assets.

    Then this changes per service but it will usually build the golang
    code in the api directory.

Thomas Ieong

reply via email to

[Prev in Thread] Current Thread [Next in Thread]