Rain 🚱 is a user on cybre.space. You can follow them or interact with them if you have an account anywhere in the fediverse.

hmm
would a package manager be a good idea? πŸ€”
it sure doesn't need one now but... if there was more software for it???

Rain 🚱 @grainloom

@enkiv2 I think so. If it's anything like pacman it would need to be a proper union file system (which afaik Plan 9's is not) and it would probably need some caching to make lookups faster.
So you could maybe do something like
% echo 'require lua-5.2' >> /srv/packagefs
and a subsequent
% /bin/lua
would find the relevant version

it's like and except you have to do less fighting against the OS

Β· Web Β· 1 Β· 0

@grainloom Why not just have a union filesystem that essentially contains all possible version of all possible packages (autovivified when first read or executed)?

@enkiv2 Because for packages you want dependencies to also be loaded. It can be implemented with a union fs underneath, but it's better if you have a service that knows about packaging and can do dependency resolution and cleanup.
(but not installation/deletion, that should be left to a separate command line utility)

@enkiv2 @grainloom (packages in the package manager should use the absolute path /pacman/packagename/filename, you only link them for convenience reasons)

@SoniEx2 @enkiv2 Well, yes, that is essentially what does afaik. On Plan 9 you wouldn't actually create a symlink tho, you would mount the package roots into a union file system

@grainloom @enkiv2 and then rely on the standard OS cache, and add offline mode support if you want

@SoniEx2 @enkiv2 Yeah, the standard caching is probly enough. Not sure what you mean by offline mode.

@grainloom @enkiv2 oh for when you accidentally stick a knife across the ethernet cables

@SoniEx2 @enkiv2 You can just save the packages yourself if you want to, there is nothing stopping you.
Or query what is loaded and download it.

@enkiv2 @SoniEx2
And if you want to use multiple package stores:

just `bind -a` them over /pacman/

@grainloom @enkiv2 As I understand Plan 9's mount semantics, why *wouldn't* it be a union filesystem?

@vertigo @enkiv2 It's not a deep union afaik, but you usually don't notice that because you usually don't mount deep directory trees.

cs.cmu.edu/~412/history/2004S/

@grainloom @enkiv2 I see what you mean; this quote:
""""
After the command
% bind -b b a # binds b on top of a
aaa.txt will be not be visible.
"""
explains everything nicely. Thanks!

@enkiv2 @grainloom how do you define 'subsequent'? does package installation race with program execution?

@martensitingale @enkiv2 I mean, probably... but the echo will block until the package is mounted and afaik file servers usually use coroutines, so there shouldn't be a situation where one thread is still registering the packages and the other is trying to serve it to a client.

@enkiv2 @martensitingale
And if the package handling service is separate from the union file system service then you don't even have to worry about dependency resolution blocking your file server.