mirror of
https://github.com/facebook/react-native.git
synced 2026-11-18 20:19:07 +00:00
Summary: This isolates and parallelize all the BUCK related work inside a `test_buck` job, so it's immediately clear where a failure happend. I've also added a couple of minor improvements: - Don't clone okbuck just to consume a script. I've copied the script over instead. - Removed unnecessary `buck_cache_key` This should reduce ~5 minute of build time from Test Android which was already beyond 10 minutes. ## Changelog [Internal] - Isolate the buck OSS commands inside test_buck Pull Request resolved: https://github.com/facebook/react-native/pull/34378 Test Plan: Let's wait for a `test_buck` and `test_android` output. Reviewed By: cipolleschi Differential Revision: D38580359 Pulled By: cortinico fbshipit-source-id: 8b3915bbc28b4a7a169011fe9047f402c2d1f6ee
26 lines
813 B
Bash
Executable File
26 lines
813 B
Bash
Executable File
#!/bin/bash
|
|
# Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
#
|
|
# This source code is licensed under the MIT license found in the
|
|
# LICENSE file in the root directory of this source tree.
|
|
|
|
# Get script directory
|
|
prog="$0"
|
|
while [ -h "${prog}" ]; do
|
|
newProg=$(/bin/ls -ld "${prog}")
|
|
newProg=$(expr "${newProg}" : ".* -> \(.*\)$")
|
|
if expr "x${newProg}" : 'x/' >/dev/null; then
|
|
prog="${newProg}"
|
|
else
|
|
progdir=$(dirname "${prog}")
|
|
prog="${progdir}/${newProg}"
|
|
fi
|
|
done
|
|
DIR=$(dirname "${prog}")
|
|
|
|
# We download saxon from Maven Central rather than copying it over.
|
|
curl https://repo1.maven.org/maven2/net/sf/saxon/Saxon-HE/9.7.0-11/Saxon-HE-9.7.0-11.jar --output "$DIR/saxon.jar"
|
|
|
|
# Perform conversion
|
|
java -jar "$DIR/saxon.jar" -xsl:"$DIR/buckToJunit.xsl" -s:"$1" -o:"$2"
|