[lsb-discuss] lsb-discuss Digest, Vol 120, Issue 1

Cyril Hrubis chrubis at suse.cz
Tue Nov 1 15:33:15 UTC 2016


Hi!
> I'm proposing a standard way to define important directories by means of variables, so, instead of having
> echo > /dev/null 2>&1 ;
> we would have 
> echo > $DEVDIR/null 2>&1 ;
> This way we don't get errors of file not found. And it will work in any machine, I mean, machines with non standard file hierarchy. 

Having null anywhere else than in /dev/ is against FHS[1] which is part
of LSB[2]. I would say that it is pretty much fine to hardcode paths to
files that are required to be there by the standard anyway.

[1] https://en.wikipedia.org/wiki/Filesystem_Hierarchy_Standard
[2] https://wiki.linuxfoundation.org/lsb/fhs

-- 
Cyril Hrubis
chrubis at suse.cz


More information about the lsb-discuss mailing list