this post was submitted on 23 Feb 2024
8 points (100.0% liked)

Guix

317 readers
2 users here now

Guix is an advanced distribution of the GNU operating system developed by the GNU Project

founded 4 years ago
MODERATORS
 

I am thinking about moving to Guix, and was wondering what you all think of Shepherd?

What are things you like? What are its shortcomings? Any cool or weird things you wish you knew before using it?

For context, I am currently using Runnit.

top 7 comments
sorted by: hot top controversial new old
[–] [email protected] 2 points 4 days ago* (last edited 4 days ago) (1 children)

I miss 'systemctl poweroff' (haven't learned the new herd equivalent); also, 'herd --help' doesn't really give any useful information and only lists a few things you can do... Have to really dig into the documentation (someday). Also, the 'shutdown' syntax has changed... Otherwise, most stuff has gone well

[–] [email protected] 2 points 4 days ago* (last edited 4 days ago) (1 children)

You can use shutdown or reboot - but it will require privilege escalation with sudo. The desktop environment's shutdown and reboot command should be working fine, just the way it is intended to. systemd is not an init system, but all the software tools crammed into one. Other init systems, including shepherd tries to keeps it simple and clean.

[–] [email protected] 1 points 4 days ago (1 children)

What I mean with shutdown, is the flags have changed (So, I can't do 'shutdown -hP' or 'shutdown -hP now')

[–] [email protected] 2 points 4 days ago* (last edited 4 days ago) (1 children)

With that respect, you're not wrong. shutdown is actually a Guile script:

#!/gnu/store/mfkz7fvlfpv3ppwbkv0imb19nrf95akf-guile-3.0.9/bin/guile --no-auto-compile
-*- scheme -*-
!#

(set! %load-path (cons "/gnu/store/r8qkjgpsy4zy982y8zifryi4n6b3qnvs-shepherd-0.10.5/share/guile/site/3.0" %load-path))
(set! %load-compiled-path (cons "/gnu/store/r8qkjgpsy4zy982y8zifryi4n6b3qnvs-shepherd-0.10.5/lib/guile/3.0/site-ccache" %load-compiled-path))
(apply (@ (shepherd scripts halt) main) (cdr (command-line)))

Now, interestingly, there is also another command called halt, which also happens to be a Guile script:

#!/gnu/store/mfkz7fvlfpv3ppwbkv0imb19nrf95akf-guile-3.0.9/bin/guile --no-auto-compile
-*- scheme -*-
!#

(set! %load-path (cons "/gnu/store/r8qkjgpsy4zy982y8zifryi4n6b3qnvs-shepherd-0.10.5/share/guile/site/3.0" %load-path))
(set! %load-compiled-path (cons "/gnu/store/r8qkjgpsy4zy982y8zifryi4n6b3qnvs-shepherd-0.10.5/lib/guile/3.0/site-ccache" %load-compiled-path))
(apply (@ (shepherd scripts halt) main) (cdr (command-line)))

This needs to be documented properly.

[–] [email protected] 1 points 4 days ago

Dang, I had no idea and never thought to inspect it; thank you for pointing that out, now maybe I can finally figure out how to nicely shutdown from the terminal

[–] [email protected] 3 points 8 months ago* (last edited 8 months ago)

It is quite basic still and historically had some problems with reboots, but lately it has gained a lot of attention and bug fixes. I have no experience of runnit, compared to systemd is leaner but in my experience there's no big feature lacking

[–] [email protected] 2 points 8 months ago

So far, I haven't faced any problem. But yes, the permission is a bit messy.