Created
March 1, 2017 15:47
-
-
Save UtahCampusD/9fe47e8eea2a54558fb22e1c2deed3cd to your computer and use it in GitHub Desktop.
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
{% set my_list = [ 'item1','item2','item3','item4'] %} | |
{% if grains['some_grain'] in my_list %} | |
# it's on the list, do something | |
{% else %} | |
# not on the list, do nothing | |
{% endif %} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment