[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Scripts that should run on different distros - Was: [SOLVED]Re: Squeeze X86 with 4GByte RAM?



On Mon, 08 Apr 2013 19:38:56 +0200, Kevin Chadwick <ma1l1ists@yahoo.co.uk> wrote:
And start your display manager with /etc/init.d/?dm restart

It's correct to explain it on a Debian list, as it is for Debian. Allow me a OT note/question. Since the issue is solved, I guess it's ok to capture this thread? Hm? I better start a new one. I'm using different Linux [1] so I stopped writing scripts using e.g. CPU frequency setup tools, instead I set it up by /sys/devices/system and regarding to other issues I use wrappers, e.g. "service".

spinymouse11.2@suse11-2:~> cat /media/archlinux/usr/local/bin/service
#!/bin/sh

exec /etc/rc.d/$1 $2

So for Debian it would be

exec /etc/init.d/$1 $2

It's also possible to write a script for several distros, cat /etc/issue and then to continue with the commands and paths for that distro, but than all scripts become unneeded bloated.

How do you handle to run scripts for different distros? Linux distros always were a little bit different, but nowadays it's very much that differs.

Regards,
Ralf

[1] What is the correct plural of "Linux"?


Reply to: