forked from ocaml/opam
-
Notifications
You must be signed in to change notification settings - Fork 0
98 lines (93 loc) · 2.37 KB
/
main.yml
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
name: Builds, tests & co
on:
push:
paths:
- 'src/**'
- '!src/tools/**'
- 'src_ext/**'
- 'dune'
- 'dune-project'
- '*.opam'
- 'Makefile*'
- 'configure*'
pull_request:
paths:
- 'src/**'
- '!src/tools/**'
- 'src_ext/**'
- 'dune'
- 'dune-project'
- '*.opam'
- 'Makefile*'
- 'configure*'
- '.github/scripts/**'
- '.github/workflows/main.yml'
- 'tests/**'
- '!tests/bench/**'
- 'shell/'
# paths-ignore:
# - 'release/**'
# - 'shell/**'
# - 'admin-scripts/**'
# - 'doc/**'
# - 'CHANGES'
# - 'LICENSE'
# - 'CONTRIBUTING.md'
# - 'master_changes.md'
# - 'README.md'
env:
OPAMBSVERSION: 2.1.0
OPAMBSROOT: ~/.cache/.opam.cached
OPAM12CACHE: ~/.cache/opam1.2/cache
OPAM_REPO: https://github.com/ocaml/opam-repository.git
OPAM_TEST_REPO_SHA: b251e0d9d0a8bcb0742d4d495c70f479effe16c2
OPAM_REPO_SHA: b251e0d9d0a8bcb0742d4d495c70f479effe16c2
SOLVER:
CYGWIN_MIRROR: http://mirrors.kernel.org/sourceware/cygwin/
CYGWIN_ROOT: D:\cygwin
CYGWIN: winsymlinks:native
CYGWIN_EPOCH: 3
defaults:
run:
shell: bash
jobs:
####
# Caches
####
Analyse:
runs-on: ubuntu-latest
steps:
- name: what are the labels
env:
LABEL: ${{ github.event.labels.name }}
run: |
echo ${{ github.event.labels.name }}
echo "x$LABEL"
- name: check pr binaries
if: ${{ contains(github.event.*.labels.*.name, 'PR:BINARIES') }}
run: echo "found!!!"
- name: check bug
if: ${{ contains(github.event.*.labels.*.name, 'bug') }}
run: echo "found!!!"
- name: current labels
run: gh api --jq '.labels.[].name' /repos/rjbou/opam/pulls/${{ github.event.number }}
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: ret labels
shell: bash
id: labell
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
cur_label=$(gh api --jq '.labels.[].name' /repos/rjbou/opam/pulls/${{ github.event.number }} | tr -d '\n')
echo "cur_label=$cur_label" >> $GITHUB_OUTPUT
# - name: labels
# run: echo ${{ steps.labell.outputs.cur_label }}
# - name: labels
# if: contains(steps.labell.outputs.cur_label , 'PR:BINARIES')
# run: echo "found!!!"
- name: what are the labels
env:
GITHUB_CONTEXT: ${{ toJson(github) }}
run: |
echo "$GITHUB_CONTEXT"