The officially official Devuan Forum!

You are not logged in.

#1 2022-08-08 06:33:32

EDX-0
Member
Registered: 2020-12-12
Posts: 53  

SHED init independient/agnostic user services

this is very much a work in progress, still testing some functions before i can consider i'm at v0.0.0 but at the current state you can get a good idea of how it works, while the client component is mostly ready i've been rewriting some functions of the daemon to be able to do "start all" and "start service_name" gracefully from the same function, anyway here is the codeberg repo, will create the mirrors on github and gitlab later.

more details on the readme

https://codeberg.org/eylles/shed

yes i DO gotta improve the wording of that readme.

Offline

#2 2022-08-10 16:02:29

EDX-0
Member
Registered: 2020-12-12
Posts: 53  

Re: SHED init independient/agnostic user services

okay, now shed is on a working state i just have to really iron out the kinks, i'm already running it on my .xsession and did reload the session services, i would be really glad if anyone who has knowledge of sysvinit and init scripts take a look and comment on my approach.

Offline

#3 2022-08-11 10:23:00

Head_on_a_Stick
Member
From: London
Registered: 2019-03-24
Posts: 3,125  
Website

Re: SHED init independient/agnostic user services

Interesting project, thanks for sharing.

I've not tried it yet but glancing over the code I noticed the XDG_CONFIG_HOME reference in shed — not all distributions set that variable explicitly so it might be best to fallback to the recognised default if it is not set:

ServicesDir="${XDG_CONFIG_HOME:-~/.config}"/shed/services

Reference: https://gitlab.freedesktop.org/xdg/xdg- … g-user-dir

And shellcheck.net noticed this in shedc:

Line 90:
  reload) killchilds "all"; printf 'reload\n' > "${GUISessionDir}/socket" ;;
                            ^-- SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).

I think it's because the killchilds() function has exit 0 at the end so the printf command won't be run afterwards. But I might be wrong.

Last edited by Head_on_a_Stick (2022-08-11 10:23:33)


Brianna Ghey — Rest In Power

Offline

#4 2022-08-11 20:55:48

EDX-0
Member
Registered: 2020-12-12
Posts: 53  

Re: SHED init independient/agnostic user services

thanks, added the fallback for the XDG_CONFIG_HOME variable, haven't had the time to test that the reload function works as intended but will give it a try as soon as possible and correct it as needed.

Offline

#5 2022-08-12 09:43:55

EDX-0
Member
Registered: 2020-12-12
Posts: 53  

Re: SHED init independient/agnostic user services

yep the printf didn't ran after the killchilds() function was done, that has been corrected now, also added a basic makefile, this combined with the reloading capability of shed working properly makes it easier to test changes and commit them as i go.

Offline

#6 2022-08-22 03:10:00

EDX-0
Member
Registered: 2020-12-12
Posts: 53  

Re: SHED init independient/agnostic user services

ah well, a little status update for those interested in shed, i will put out a release tag once i'm done with another 3 points of the todo list on the repo.

as for showing the status i went for something that those acquainted with sysvinit will find familiar.
hpg5Vyg.png

Offline

#7 2022-10-02 08:28:03

EDX-0
Member
Registered: 2020-12-12
Posts: 53  

Re: SHED init independient/agnostic user services

the first version of shed, v.0.0.0 is finally out

https://codeberg.org/eylles/shed/releases

after this i plan to work on the rest of intended features, bash completion and a man page.

Offline

Board footer