build: add Linux GHA build step (#42432)
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
This commit is contained in:
parent
83748bd181
commit
ffe1d70f1d
4 changed files with 322 additions and 34 deletions
|
@ -1,17 +1,25 @@
|
|||
#!/bin/bash
|
||||
|
||||
set -eo pipefail
|
||||
|
||||
mv_if_exist() {
|
||||
if [ -f "generated_artifacts_${BUILD_TYPE}_${TARGET_ARCH}/$1" ] || [ -d "generated_artifacts_${BUILD_TYPE}_${TARGET_ARCH}/$1" ]; then
|
||||
echo Restoring $1 to $2
|
||||
mkdir -p $2
|
||||
mv generated_artifacts_${BUILD_TYPE_${TARGET_ARCH}}/$1 $2
|
||||
mv generated_artifacts_${BUILD_TYPE}_${TARGET_ARCH}/$1 $2
|
||||
else
|
||||
echo Skipping $1 - It is not present on disk
|
||||
fi
|
||||
}
|
||||
|
||||
untar_if_exist() {
|
||||
if [ -f "generated_artifacts_${BUILD_TYPE}_${TARGET_ARCH}/$1" ] || [ -d "generated_artifacts_${BUILD_TYPE}_${TARGET_ARCH}/$1" ]; then
|
||||
echo Restoring $1 to $2
|
||||
tar -xf generated_artifacts_${BUILD_TYPE}_${TARGET_ARCH}/$1 $2
|
||||
else
|
||||
echo Skipping $1 - It is not present on disk
|
||||
fi
|
||||
}
|
||||
|
||||
# Restore generated artifacts
|
||||
mv_if_exist dist.zip src/out/Default
|
||||
mv_if_exist node_headers.tar.gz src/out/Default/gen
|
||||
mv_if_exist symbols.zip src/out/Default
|
||||
|
@ -19,4 +27,7 @@ mv_if_exist mksnapshot.zip src/out/Default
|
|||
mv_if_exist chromedriver.zip src/out/Default
|
||||
mv_if_exist ffmpeg.zip src/out/ffmpeg
|
||||
mv_if_exist hunspell_dictionaries.zip src/out/Default
|
||||
mv_if_exist cross-arch-snapshots src
|
||||
mv_if_exist cross-arch-snapshots src
|
||||
|
||||
# Restore build artifacts
|
||||
untar_if_exist build_artifacts.tar ./
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue