-
Notifications
You must be signed in to change notification settings - Fork 0
58 lines (48 loc) · 1.52 KB
/
build.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
name: build
on:
push:
branches:
- main
pull_request:
schedule:
# At 00:00 on Monday
- cron: '0 0 * * 1'
concurrency:
group: ${{ github.workflow }}-${{ github.event.number || github.ref }}
cancel-in-progress: true
env:
# renovate: datasource=github-releases depName=jsonnet-bundler/jsonnet-bundler
JB_VERSION: v0.6.0
# renovate: datasource=github-releases depName=google/go-jsonnet
JSONNET_VERSION: v0.20.0
jobs:
build:
name: build
runs-on: ubuntu-latest
timeout-minutes: 60
defaults:
run:
working-directory: examples
steps:
- name: Checkout
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
- name: Set up Jsonnet
run: |
mkdir -p "${HOME}/.local/bin"
echo "${HOME}/.local/bin" >>"${GITHUB_PATH}"
gh --repo=google/go-jsonnet release download "${JSONNET_VERSION}" \
--output=- --pattern='go-jsonnet_*_Linux_x86_64.tar.gz' \
| tar -zxvf - -C "${HOME}/.local/bin" jsonnet jsonnet-lint jsonnetfmt
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Set up Jsonnet Bundler
run: |
gh --repo=jsonnet-bundler/jsonnet-bundler release download "${JB_VERSION}" \
--output="${HOME}/.local/bin/jb" --pattern=jb-linux-amd64
chmod +x "${HOME}/.local/bin/jb"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Lint examples
run: make lint
- name: Build examples
run: make