mirror of
https://github.com/facebook/react-native.git
synced 2024-11-21 12:39:27 +00:00
Use realpath instead of readlink
Summary: Changelog: [Internal] Generated with: ``` python3 codemod.py -d xplat/js --extensions=sh 'THIS_DIR=\$\(cd -P "\$\(dirname "\$\(readlink "\${BASH_SOURCE\[0\]}"' 'THIS_DIR=$(cd -P "$(dirname "$(realpath "${BASH_SOURCE[0]}"'``` Reviewed By: motiz88 Differential Revision: D34379955 fbshipit-source-id: c60521cd6508b203f48ca8c890c450319991c2d4
This commit is contained in:
parent
6b5c3db9c2
commit
bb8ddd6c12
@ -6,7 +6,7 @@
|
||||
|
||||
# This script assumes yarn is already installed.
|
||||
|
||||
THIS_DIR=$(cd -P "$(dirname "$(readlink "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
THIS_DIR=$(cd -P "$(dirname "$(realpath "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
|
||||
set -e
|
||||
set -u
|
||||
|
@ -7,7 +7,7 @@
|
||||
set -e
|
||||
set -u
|
||||
|
||||
THIS_DIR=$(cd -P "$(dirname "$(readlink "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
THIS_DIR=$(cd -P "$(dirname "$(realpath "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
|
||||
# shellcheck source=xplat/js/env-utils/setup_env_vars.sh
|
||||
source "$THIS_DIR/../../../../../../env-utils/setup_env_vars.sh"
|
||||
|
@ -7,7 +7,7 @@
|
||||
set -e
|
||||
set -u
|
||||
|
||||
THIS_DIR=$(cd -P "$(dirname "$(readlink "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
THIS_DIR=$(cd -P "$(dirname "$(realpath "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
|
||||
# shellcheck source=xplat/js/env-utils/setup_env_vars.sh
|
||||
source "$THIS_DIR/../../../../../../env-utils/setup_env_vars.sh"
|
||||
|
@ -7,7 +7,7 @@
|
||||
set -e
|
||||
set -u
|
||||
|
||||
THIS_DIR=$(cd -P "$(dirname "$(readlink "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
THIS_DIR=$(cd -P "$(dirname "$(realpath "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
|
||||
# shellcheck source=xplat/js/env-utils/setup_env_vars.sh
|
||||
source "$THIS_DIR/../../../../../../env-utils/setup_env_vars.sh"
|
||||
|
@ -6,7 +6,7 @@
|
||||
|
||||
# This script should be run from the react-native root
|
||||
|
||||
THIS_DIR=$(cd -P "$(dirname "$(readlink "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
THIS_DIR=$(cd -P "$(dirname "$(realpath "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
source "scripts/.tests.env"
|
||||
|
||||
if [ -n "$1" ]
|
||||
|
@ -78,7 +78,7 @@ xcprettyFormat() {
|
||||
# Circle CI expects JUnit reports to be available here
|
||||
REPORTS_DIR="$HOME/react-native/reports/junit"
|
||||
else
|
||||
THIS_DIR=$(cd -P "$(dirname "$(readlink "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
THIS_DIR=$(cd -P "$(dirname "$(realpath "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
|
||||
# Write reports to the react-native root dir
|
||||
REPORTS_DIR="$THIS_DIR/../build/reports"
|
||||
|
@ -5,7 +5,7 @@
|
||||
# LICENSE file in the root directory of this source tree.
|
||||
|
||||
# scripts directory
|
||||
THIS_DIR=$(cd -P "$(dirname "$(readlink "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
THIS_DIR=$(cd -P "$(dirname "$(realpath "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
REACT_NATIVE_ROOT="$THIS_DIR/.."
|
||||
# Application root directory - General use case: react-native is a dependency
|
||||
PROJECT_ROOT="$THIS_DIR/../../.."
|
||||
|
@ -10,7 +10,7 @@
|
||||
# virtual device configuration.
|
||||
# This is useful for running integration tests on a local machine.
|
||||
|
||||
THIS_DIR=$(cd -P "$(dirname "$(readlink "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
THIS_DIR=$(cd -P "$(dirname "$(realpath "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
|
||||
STATE=`adb get-state`
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
# Usage:
|
||||
# source scripts/update_podfile_lock && update_pods
|
||||
|
||||
THIS_DIR=$(cd -P "$(dirname "$(readlink "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
THIS_DIR=$(cd -P "$(dirname "$(realpath "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd)
|
||||
RNTESTER_DIR="$THIS_DIR/../packages/rn-tester"
|
||||
|
||||
# Keep this separate for FB internal access.
|
||||
|
Loading…
Reference in New Issue
Block a user