You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
245 B
18 lines
245 B
2 years ago
|
#!/usr/bin/env bash
|
||
|
set -x
|
||
|
name="$1"
|
||
|
|
||
|
if [[ "$name" == '' ]]; then
|
||
|
dirs=(*/)
|
||
|
else
|
||
|
dirs=(.)
|
||
|
fi
|
||
|
|
||
|
for dir in ${dirs[@]}; do
|
||
|
echo "> Extracting: $dir"
|
||
|
pushd "$dir" > /dev/null
|
||
|
tar xvf artifact.tar
|
||
|
rm artifact.tar
|
||
|
popd > /dev/null
|
||
|
done
|