combining class guards

8 views
Skip to first unread message

Christian Linden

unread,
Nov 14, 2016, 11:17:26 AM11/14/16
to help-cfengine
Hi,

what does:
class1.class2|class3::
mean?

1. class1 AND class2 OR JUST class3
2. class1 AND class2 OR class1 AND class3
?

=)

Chris

Neil Watson

unread,
Nov 14, 2016, 11:24:45 AM11/14/16
to help-cfengine
https://docs.cfengine.com/docs/3.7/guide-language-concepts-classes.html#operators-and-precedence
And takes precedence over or, but I tend to use brackets so I don't have
to think about it.

(class1.class2)|class3::

--
Neil H Watson @neil_h_watson
CFEngine reporting: https://github.com/neilhwatson/delta_reporting
CFEngine policy: https://github.com/neilhwatson/evolve_cfengine_freelib
CFEngine and vim: https://github.com/neilhwatson/vim_cf3

Christian Linden

unread,
Nov 14, 2016, 11:37:24 AM11/14/16
to help-cfengine, cfen...@watson-wilson.ca
I prefer the choice of brackets, too; thanks Neil! =)
Reply all
Reply to author
Forward
0 new messages