unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Thomas Ieong <th.ieong@free.fr>
To: guix-devel@gnu.org
Subject: Sourcehut packaging in 2023
Date: Mon, 06 Mar 2023 09:48:03 +0100	[thread overview]
Message-ID: <878rga9sfw.fsf@free.fr> (raw)

Hi,

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
assets.

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.

    - core.sr.ht:

    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 core.sr.ht you will need to run setup.py.

    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
    assets.


    - *.sr.ht

    Now the generic build method for all other sourcehut services.

    You run setup.py in the root directory, it contains a call to a
    Makefile in that same directory and this Makefile will include the
    Makefile from core.sr.ht 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	other threads:[~2023-03-06 17:03 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=878rga9sfw.fsf@free.fr \
    --to=th.ieong@free.fr \
    --cc=guix-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).