Re: [fr] Moment de convivialité Guix@Paris en mars

2024-02-29 Thread Thomas Ieong
Salut,

Ca fait un moment que j'ai envie de venir mais les dates s'accordaient
pas, j'ai enfin du temps ;)

Au plaisir !
-- 
Thomas Ieong



Sourcehut packaging in 2023

2023-03-06 Thread Thomas Ieong
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