Created
August 29, 2013 23:01
-
-
Save nicklewis/6384464 to your computer and use it in GitHub Desktop.
Hypothetical PuppetDB ternary operator
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
["and", | |
["=", "type", "Package"], | |
["?:", | |
["in", "certname", | |
["extract", "certname", | |
["select-facts", | |
["and", ["=", "name", "kernelrelease"], ["=", "value", "3.2.0-3-amd64"]]]]] | |
["=", "title", "linux-headers-3.2.0-3-amd64"], | |
["=", "title", "linux-headers-3.2.0-2-amd64"]]] | |
["and", | |
["=", "type", "Package"], | |
["or", | |
["and", | |
["in", "certname", | |
["extract", "certname", | |
["select-facts", | |
["and", ["=", "name", "kernelrelease"], ["=", "value", "3.2.0-3-amd64"]]]]], | |
["=", "title", "linux-headers-3.2.0-3-amd64"]], | |
["and", | |
["not", | |
["in", "certname", | |
["extract", "certname", | |
["select-facts", | |
["and", ["=", "name", "osfamily"], ["=", "value", "3.2.0-3-amd64"]]]]]], | |
["=", "title", "linux-headers-3.2.0-2-amd64"]]]] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment