Re: Questions: 0mirror; automation.

Thomas Leonard <[email protected]> Fri, 2 Feb 2024 13:33:16 +0000
Newsgroups gmane.comp.file-systems.zero-install.devel
Message-ID <CAG4opy_FVaS3akeJm8ouBSK7LaOwzy3K2509TEA6tFB6vH_fDA@mail.gmail.com>
On Wed, 24 Jan 2024 at 08:01, Mateusz Czaplinski <[email protected]> wrote:
>
> Hi All,
> I have two completely separate questions:
>
> 1. A while ago I kindly asked for my catalog (https://akavel.github.io/0catalog/catalog.xml) to be added to 0mirror, which was done. Very recently I noticed, that many (all?) new feeds I added to my catalog since then do not seem mirrored. That surprised me - I assumed that adding a catalog to 0mirror is a one-time thing, and it gets synced automatically in the future; but it looks like I misunderstood this. Is that so? Should I understand that every time I add a new feed to my catalog, I need to manually request for the mirror to be updated, if I want to share my slowly growing list of feeds with the community to make it widely available?

Updating the list currently requires me to run a script, which I don't
do very often. It should have added them now.

> 2. I'm trying to write an experimental tool to automate my machines' configurations. Somewhat inspired by Nix, but much less ambitious, and notably with support for Windows. For many reasons, I would love to be able to have it manage locally installed apps via 0install automation. However, I'm struggling with finding the right way to do that, among the myriad subcommands of 0install. The one thing I found that seems somewhat relevant, is `0install list-apps --xml` (paired with `0install install-apps`). However, I'm still having two challenges with it:
>
>   (1) it seems only available on Windows, at least according to the website;
>   (2) I don't seem to see the precise, deterministic versions (digests?) of installed (cached?) implementations listed in the output.
>
> For my tool's idea it is important for me to strive for a 100% deterministic description of a system, thus I would really like to be able to both export as well as apply a list of apps with exact versions/digests, and also be able to do it on Windows as well as on Linux/other OSes.
>
> Could you help me understand if there's a way I could do it?

I don't think there's a command for it, but you can do e.g.

$ ls ~/.config/0install.net/apps/
foo
...

$ 0install show --xml foo
[ includes <manifest-digest> elements ]

Since Nix added flakes, I'm mostly using that these days, but the lack
of Windows support does limit it if you need portability.


-- 
talex5 (GitLab/GitHub), @[email protected]
http://roscidus.com/blog/