-
Notifications
You must be signed in to change notification settings - Fork 0
executable file
·43 lines (42 loc) · 1.04 KB
/
Copy pathfifteenth_workflow.yml
File metadata and controls
executable file
·43 lines (42 loc) · 1.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
name: Fifteenth Workflow
on: push
jobs:
first-jobs:
runs-on: ubuntu-latest
steps:
- name: Math expression
run: expr 2 + 2 > math-result.txt
- name: Upload result file
uses: actions/upload-artifact@v3
with:
name: math-result
path: math-result.txt
another-job:
runs-on: ubuntu-latest
needs: first-jobs
steps:
- name: Download file
uses: actions/download-artifact@v3
with:
name: math-result
- name: Math Expression
run: |
value=`cat math-result.txt`
expr $value \* 2 > math-result.txt
- name: Upload result file
uses: actions/upload-artifact@v3
with:
name: math-result
path: math-result.txt
second-job:
runs-on: ubuntu-latest
needs: another-job
steps:
- name: Download file
uses: actions/download-artifact@v3
with:
name: math-result
- name: Print File
run: |
value=`cat math-result.txt`
echo $value