On 2018-04-15 18:10, David C. Rankin wrote:
On 04/15/2018 10:40 AM, Per Jessen wrote:
Just wondering why you woulnd't source it, and evaluate the variables directly?
. /etc/os-release if test "$ID" = "opensuse" then ... elseif test "$ID" = "arch" then ...
I generally don't source anything I didn't create or have control over the contents of in my startup scripts. I also try and remain POSIX shell compliant. It's just personal preference. It could be sourced, but then unless I check the file on each update, I don't know if there are any new potentially conflicting names that may get pulled in.
But this file was designed to be simply sourced. It is faster than running grep or sed on it. -- Cheers / Saludos, Carlos E. R. (from 42.3 x86_64 "Malachite" at Telcontar)