-
Notifications
You must be signed in to change notification settings - Fork 3
/
examples.sh
executable file
·69 lines (57 loc) · 1.58 KB
/
examples.sh
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
#!/usr/bin/env bash
set -eux
error() {
echo >&2 "error: $*"
exit 1
}
command -v gh-release-install > /dev/null || error "gh-release-install command not found!"
TMP_DIR=$(mktemp -d)
pushd "$TMP_DIR"
gh-release-install -vv \
'prometheus/node_exporter' \
'node_exporter-{version}.linux-amd64.tar.gz' \
--extract 'node_exporter-{version}.linux-amd64/node_exporter' \
"node_exporter" \
--version 'v1.2.2' \
--version-file '{destination}.version' \
--checksum 'sha256:sha256sums.txt'
gh-release-install -vv \
'mvdan/sh' \
'shfmt_{tag}_linux_amd64' \
'shfmt' \
--version-file '{destination}.version'
gh-release-install -vv \
'mvdan/sh' \
'shfmt_{tag}_linux_amd64' \
'shfmt' \
--version 'v3.3.1' \
--version-file '{destination}.version'
gh-release-install -vv \
'mvdan/sh' \
'shfmt_{tag}_linux_amd64' \
'.' \
--version 'v3.3.1' \
--version-file '{destination}.version'
gh-release-install -vv \
'grafana/loki' \
'loki-linux-amd64.zip' \
--extract 'loki-linux-amd64' \
'loki' \
--version 'v2.2.1' \
--checksum 'sha256:SHA256SUMS'
gh-release-install -vv \
'grafana/loki' \
'loki-linux-amd64.zip' \
--extract 'loki-linux-amd64' \
'loki' \
--version 'v2.2.1' \
--checksum 'sha256:dacfb229dbc7064b1d6390173ea6963eb3c85f60dc2336081b0113476405c5aa'
gh-release-install -vv \
'restic/restic' \
'restic_{version}_linux_amd64.bz2' \
--extract 'restic_{version}_linux_amd64' \
'restic' \
--version 'v0.12.1' \
--checksum 'sha256:SHA256SUMS'
popd
rm -Rf "$TMP_DIR"