Skip to content

Commit 14f4a2d

Browse files
committed
use "gtar" on evergreen when available
Fixes error extracting symlinks with Sun "tar" on Solaris: "typeflag 'x' not recognized".
1 parent b888ecc commit 14f4a2d

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

.evergreen/config.yml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,19 @@ functions:
9191
params:
9292
continue_on_err: true
9393
# EVG-1105: Use s3.get extract_to: mongoc/
94-
script: "set -o xtrace && mkdir mongoc && tar xf build.tar.gz -C mongoc/"
94+
script: |
95+
set -o xtrace # Write all commands first to stderr
96+
set -o errexit # Exit the script with error if any of the commands fail
97+
98+
mkdir mongoc
99+
100+
if command -v gtar 2>/dev/null; then
101+
TAR=gtar
102+
else
103+
TAR=tar
104+
fi
105+
106+
$TAR xf build.tar.gz -C mongoc/
95107
96108
"upload docs" :
97109
- command: shell.exec

0 commit comments

Comments
 (0)