Skip to content

Commit d2c0e7b

Browse files
committed
Add snippet for untar bzip2.
1 parent e430cd2 commit d2c0e7b

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
#!/usr/bin/env -S bash --noprofile --norc -o errexit -o pipefail -o noclobber -o nounset -o allexport
2+
3+
source curl_download_stdout.sh
4+
5+
curl_download_untarj() {
6+
local url=$1
7+
local strip=$2
8+
local target=$3
9+
local bin_path=$4
10+
curl_download_stdout "${url}" | tar \
11+
-xj \
12+
-f '-' \
13+
--strip-components="${strip}" \
14+
-C "${target}" \
15+
"${bin_path}"
16+
}

0 commit comments

Comments
 (0)