File tree 5 files changed +65
-0
lines changed
5 files changed +65
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Test
2
+
3
+ on :
4
+ push :
5
+ branches : [ master ]
6
+ pull_request :
7
+ branches : [ master ]
8
+
9
+ jobs :
10
+ build :
11
+
12
+ runs-on : ${{ matrix.os }}
13
+ strategy :
14
+ matrix :
15
+ python-version : [3.6, 3.7, 3.8]
16
+ os : [ubuntu-latest]
17
+
18
+ steps :
19
+ - name : Checkout
20
+ uses : actions/checkout@v2
21
+ - name : Set up Python ${{ matrix.python-version }}
22
+ uses : actions/setup-python@v1
23
+ with :
24
+ python-version : ${{ matrix.python-version }}
25
+ - name : Run the test
26
+ run : |
27
+ python test.py
Original file line number Diff line number Diff line change
1
+ __pycache__ /
2
+ * .pyc
Original file line number Diff line number Diff line change
1
+ # Forking workflow exercise with taco recipes
2
+
3
+ Exercise description: https://coderefinery.github.io/git-collaborative/distributed/
Original file line number Diff line number Diff line change
1
+
2
+
3
+ # Cauliflower tacos
4
+
5
+ This recipe is taken as an example from https://github.com/sinker/tacofancy/blob/master/full_tacos/cauliflower_tacos.md .
6
+
7
+ We are avid meat eaters, but these vegetarian tacos are one of our go-tos in
8
+ Peru. If you can make the pickles with Peruvian aji amarillo, please do.
9
+
10
+ - Roast cauliflower
11
+ - Pickled chilis and vegetables
12
+ - Caramelized red onions
13
+ - Guacamole
14
+ - Yogurt
15
+ - Tortilla of choice, warmed in a dry pan
Original file line number Diff line number Diff line change
1
+ """
2
+ This will loop through all files *.md and check that they contain the string
3
+ 'taco' (case-insensitive).
4
+ """
5
+
6
+ from __future__ import print_function
7
+ import os
8
+ import sys
9
+
10
+ for filename in os .listdir ("." ):
11
+ if filename .endswith (".md" ):
12
+ with open (filename , 'r' ) as f :
13
+ recipe = f .read ().lower ()
14
+ if not 'taco' in recipe :
15
+ print ("file {0} contains no string 'taco'" .format (filename ), file = sys .stderr )
16
+ sys .exit (1 )
17
+
18
+ print ("all *.md files contain the string 'taco'" )
You can’t perform that action at this time.
0 commit comments