Artix Linux Forum

Artix Linux => System => Topic started by: mardiyah on 08 June 2022, 19:52:50

Title: How doing openRC setup
Post by: mardiyah on 08 June 2022, 19:52:50
How did this fail, what actually the mistake:

Code: [Select]
$ sudo openrc-run userAutoStart.sh start
userAutoStart.sh  | * The command variable is undefined.
userAutoStart.sh  | * There is nothing for userAutoStart.sh to start.
userAutoStart.sh  | * If this is what you intend, please write a start function.
userAutoStart.sh  | * This will become a failure in a future release.

The script is calling a python script

Code: [Select]
$ cat   userAutoStart.sh 

#!/sbin/openrc-run

xbacklight -set 40

Please show the fixing solution, thanks before
Title: Re: How doing openRC setup
Post by: nous on 08 June 2022, 22:53:01
This is not the way to write and invoke openrc init scripts. Get a simple script from /etc/init.d and work upon it.
Title: Re: How doing openRC setup
Post by: mardiyah on 09 June 2022, 02:58:22
How ?
This actually try to do auto start of a shell script invoking that python one, as on XFCE Session & startup tha'd fail to work
Title: Re: How doing openRC setup
Post by: tintin on 09 June 2022, 06:30:02
If you are using XFCE, you can add an item in xfce4-session-settings
See the attached screenshot.
Title: Re: How doing openRC setup
Post by: nous on 09 June 2022, 13:58:46
How ?
This actually try to do auto start of a shell script invoking that python one, as on XFCE Session & startup tha'd fail to work
Such one-liners are more suitable for /etc/rc.local (or /etc/local.d/something.start). OpenRC will execute it at every boot.
Title: Re: How doing openRC setup
Post by: mardiyah on 19 June 2022, 13:24:26
How come in your way this takes quite time at least ~ 9 seconds after desktop GUI really ready
which way faster

guess original openrc service in bash script is faster or...
Please share your golden secret
Title: Re: How doing openRC setup
Post by: Lancia on 19 June 2022, 15:47:41
How come in your way this takes quite time at least ~ 5 seconds after desktop GUI really ready
which way faster

guess original openrc service in bash script is faster or...
Please share your golden secret

What way are you using?