expo-test-runner 0.0.9 → 0.0.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintrc.js +2 -28
- package/build/BundlerController.js +7 -8
- package/build/BundlerController.js.map +1 -1
- package/build/ConfigReader.js +1 -1
- package/build/ConfigReader.js.map +1 -1
- package/build/Paths.js +1 -1
- package/build/Paths.js.map +1 -1
- package/build/TemplateEvaluator.js +6 -2
- package/build/TemplateEvaluator.js.map +1 -1
- package/build/TemplateFile.js +9 -5
- package/build/TemplateFile.js.map +1 -1
- package/build/TemplateProject.d.ts +25 -0
- package/build/TemplateProject.js +168 -0
- package/build/TemplateProject.js.map +1 -0
- package/build/Utils.js +4 -4
- package/build/Utils.js.map +1 -1
- package/build/commands/CreateProject.js +3 -3
- package/build/commands/CreateProject.js.map +1 -1
- package/build/commands/RunTest.js +8 -4
- package/build/commands/RunTest.js.map +1 -1
- package/build/index.js +1 -1
- package/build/index.js.map +1 -1
- package/build/registerCommand.js +6 -3
- package/build/registerCommand.js.map +1 -1
- package/package.json +26 -21
- package/src/BundlerController.ts +2 -2
- package/src/TemplateProject.ts +209 -0
- package/src/Utils.ts +2 -2
- package/src/commands/CreateProject.ts +2 -2
- package/src/commands/RunTest.ts +2 -2
- package/src/index.ts +1 -1
- package/src/registerCommand.ts +1 -1
- package/templates/detox/android/app/build.gradle +202 -24
- package/templates/detox/android/app/src/androidTest/java/com/testrunner/DetoxTest.java +79 -18
- package/templates/detox/android/app/src/main/java/com/testrunner/MainApplication.java +129 -0
- package/templates/detox/android/build.gradle +34 -17
- package/templates/detox/ios/devcliente2e/main.m +31 -0
- package/tsconfig.json +1 -1
- package/.prettierrc +0 -10
- package/build/Platform.ds.d.ts +0 -4
- package/build/Platform.ds.js +0 -9
- package/build/Platform.ds.js.map +0 -1
- package/build/ProjectFile.d.ts +0 -0
- package/build/ProjectFile.js +0 -2
- package/build/ProjectFile.js.map +0 -1
- package/build/TemplateParser.d.ts +0 -6
- package/build/TemplateParser.js +0 -37
- package/build/TemplateParser.js.map +0 -1
- package/build/commands/create-project.d.ts +0 -3
- package/build/commands/create-project.js +0 -12
- package/build/commands/create-project.js.map +0 -1
- package/build/presets/DetoxTemplate.d.ts +0 -13
- package/build/presets/DetoxTemplate.js +0 -79
- package/build/presets/DetoxTemplate.js.map +0 -1
- package/build/presets/PresetTemplate.d.ts +0 -25
- package/build/presets/PresetTemplate.js +0 -147
- package/build/presets/PresetTemplate.js.map +0 -1
- package/src/presets/DetoxTemplate.ts +0 -94
- package/src/presets/PresetTemplate.ts +0 -171
- package/templates/basic/android/app/BUCK +0 -55
- package/templates/basic/android/app/build.gradle +0 -188
- package/templates/basic/android/app/build_defs.bzl +0 -19
- package/templates/basic/android/app/debug.keystore +0 -0
- package/templates/basic/android/app/proguard-rules.pro +0 -10
- package/templates/basic/android/app/src/main/AndroidManifest.xml +0 -16
- package/templates/basic/android/app/src/main/java/com/testrunner/MainActivity.java +0 -28
- package/templates/basic/android/app/src/main/java/com/testrunner/MainApplication.java +0 -57
- package/templates/basic/android/app/src/main/res/mipmap-hdpi/ic_launcher.png +0 -0
- package/templates/basic/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png +0 -0
- package/templates/basic/android/app/src/main/res/mipmap-mdpi/ic_launcher.png +0 -0
- package/templates/basic/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png +0 -0
- package/templates/basic/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png +0 -0
- package/templates/basic/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png +0 -0
- package/templates/basic/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png +0 -0
- package/templates/basic/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png +0 -0
- package/templates/basic/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png +0 -0
- package/templates/basic/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png +0 -0
- package/templates/basic/android/app/src/main/res/values/styles.xml +0 -14
- package/templates/basic/android/build.gradle +0 -38
- package/templates/basic/android/gradle/wrapper/gradle-wrapper.jar +0 -0
- package/templates/basic/android/gradle/wrapper/gradle-wrapper.properties +0 -5
- package/templates/basic/android/gradle.properties +0 -26
- package/templates/basic/android/gradlew +0 -183
- package/templates/basic/android/gradlew.bat +0 -103
- package/templates/basic/android/settings.gradle +0 -10
- package/templates/basic/babel.config.js +0 -6
- package/templates/basic/ios/Podfile +0 -37
- package/templates/basic/ios/project.yml +0 -10
- package/templates/basic/ios/src/AppDelegate.h +0 -9
- package/templates/basic/ios/src/AppDelegate.m +0 -62
- package/templates/basic/ios/src/Images.xcassets/AppIcon.appiconset/Contents.json +0 -38
- package/templates/basic/ios/src/Images.xcassets/Contents.json +0 -6
- package/templates/basic/ios/src/Info.plist +0 -55
- package/templates/basic/ios/src/LaunchScreen.storyboard +0 -47
- package/templates/basic/ios/src/dummy.swift +0 -0
- package/templates/basic/ios/src/main.m +0 -9
- package/templates/basic/package.json +0 -37
- package/templates/basic/tsconfig.json +0 -6
|
@@ -1,183 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env sh
|
|
2
|
-
|
|
3
|
-
#
|
|
4
|
-
# Copyright 2015 the original author or authors.
|
|
5
|
-
#
|
|
6
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
|
-
# you may not use this file except in compliance with the License.
|
|
8
|
-
# You may obtain a copy of the License at
|
|
9
|
-
#
|
|
10
|
-
# https://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
-
#
|
|
12
|
-
# Unless required by applicable law or agreed to in writing, software
|
|
13
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
-
# See the License for the specific language governing permissions and
|
|
16
|
-
# limitations under the License.
|
|
17
|
-
#
|
|
18
|
-
|
|
19
|
-
##############################################################################
|
|
20
|
-
##
|
|
21
|
-
## Gradle start up script for UN*X
|
|
22
|
-
##
|
|
23
|
-
##############################################################################
|
|
24
|
-
|
|
25
|
-
# Attempt to set APP_HOME
|
|
26
|
-
# Resolve links: $0 may be a link
|
|
27
|
-
PRG="$0"
|
|
28
|
-
# Need this for relative symlinks.
|
|
29
|
-
while [ -h "$PRG" ] ; do
|
|
30
|
-
ls=`ls -ld "$PRG"`
|
|
31
|
-
link=`expr "$ls" : '.*-> \(.*\)$'`
|
|
32
|
-
if expr "$link" : '/.*' > /dev/null; then
|
|
33
|
-
PRG="$link"
|
|
34
|
-
else
|
|
35
|
-
PRG=`dirname "$PRG"`"/$link"
|
|
36
|
-
fi
|
|
37
|
-
done
|
|
38
|
-
SAVED="`pwd`"
|
|
39
|
-
cd "`dirname \"$PRG\"`/" >/dev/null
|
|
40
|
-
APP_HOME="`pwd -P`"
|
|
41
|
-
cd "$SAVED" >/dev/null
|
|
42
|
-
|
|
43
|
-
APP_NAME="Gradle"
|
|
44
|
-
APP_BASE_NAME=`basename "$0"`
|
|
45
|
-
|
|
46
|
-
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
|
47
|
-
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
|
48
|
-
|
|
49
|
-
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
|
50
|
-
MAX_FD="maximum"
|
|
51
|
-
|
|
52
|
-
warn () {
|
|
53
|
-
echo "$*"
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
die () {
|
|
57
|
-
echo
|
|
58
|
-
echo "$*"
|
|
59
|
-
echo
|
|
60
|
-
exit 1
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
# OS specific support (must be 'true' or 'false').
|
|
64
|
-
cygwin=false
|
|
65
|
-
msys=false
|
|
66
|
-
darwin=false
|
|
67
|
-
nonstop=false
|
|
68
|
-
case "`uname`" in
|
|
69
|
-
CYGWIN* )
|
|
70
|
-
cygwin=true
|
|
71
|
-
;;
|
|
72
|
-
Darwin* )
|
|
73
|
-
darwin=true
|
|
74
|
-
;;
|
|
75
|
-
MINGW* )
|
|
76
|
-
msys=true
|
|
77
|
-
;;
|
|
78
|
-
NONSTOP* )
|
|
79
|
-
nonstop=true
|
|
80
|
-
;;
|
|
81
|
-
esac
|
|
82
|
-
|
|
83
|
-
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
|
|
84
|
-
|
|
85
|
-
# Determine the Java command to use to start the JVM.
|
|
86
|
-
if [ -n "$JAVA_HOME" ] ; then
|
|
87
|
-
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
|
|
88
|
-
# IBM's JDK on AIX uses strange locations for the executables
|
|
89
|
-
JAVACMD="$JAVA_HOME/jre/sh/java"
|
|
90
|
-
else
|
|
91
|
-
JAVACMD="$JAVA_HOME/bin/java"
|
|
92
|
-
fi
|
|
93
|
-
if [ ! -x "$JAVACMD" ] ; then
|
|
94
|
-
die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
|
|
95
|
-
|
|
96
|
-
Please set the JAVA_HOME variable in your environment to match the
|
|
97
|
-
location of your Java installation."
|
|
98
|
-
fi
|
|
99
|
-
else
|
|
100
|
-
JAVACMD="java"
|
|
101
|
-
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
|
102
|
-
|
|
103
|
-
Please set the JAVA_HOME variable in your environment to match the
|
|
104
|
-
location of your Java installation."
|
|
105
|
-
fi
|
|
106
|
-
|
|
107
|
-
# Increase the maximum file descriptors if we can.
|
|
108
|
-
if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
|
|
109
|
-
MAX_FD_LIMIT=`ulimit -H -n`
|
|
110
|
-
if [ $? -eq 0 ] ; then
|
|
111
|
-
if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
|
|
112
|
-
MAX_FD="$MAX_FD_LIMIT"
|
|
113
|
-
fi
|
|
114
|
-
ulimit -n $MAX_FD
|
|
115
|
-
if [ $? -ne 0 ] ; then
|
|
116
|
-
warn "Could not set maximum file descriptor limit: $MAX_FD"
|
|
117
|
-
fi
|
|
118
|
-
else
|
|
119
|
-
warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
|
|
120
|
-
fi
|
|
121
|
-
fi
|
|
122
|
-
|
|
123
|
-
# For Darwin, add options to specify how the application appears in the dock
|
|
124
|
-
if $darwin; then
|
|
125
|
-
GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
|
|
126
|
-
fi
|
|
127
|
-
|
|
128
|
-
# For Cygwin or MSYS, switch paths to Windows format before running java
|
|
129
|
-
if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
|
|
130
|
-
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
|
|
131
|
-
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
|
|
132
|
-
JAVACMD=`cygpath --unix "$JAVACMD"`
|
|
133
|
-
|
|
134
|
-
# We build the pattern for arguments to be converted via cygpath
|
|
135
|
-
ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
|
|
136
|
-
SEP=""
|
|
137
|
-
for dir in $ROOTDIRSRAW ; do
|
|
138
|
-
ROOTDIRS="$ROOTDIRS$SEP$dir"
|
|
139
|
-
SEP="|"
|
|
140
|
-
done
|
|
141
|
-
OURCYGPATTERN="(^($ROOTDIRS))"
|
|
142
|
-
# Add a user-defined pattern to the cygpath arguments
|
|
143
|
-
if [ "$GRADLE_CYGPATTERN" != "" ] ; then
|
|
144
|
-
OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
|
|
145
|
-
fi
|
|
146
|
-
# Now convert the arguments - kludge to limit ourselves to /bin/sh
|
|
147
|
-
i=0
|
|
148
|
-
for arg in "$@" ; do
|
|
149
|
-
CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
|
|
150
|
-
CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
|
|
151
|
-
|
|
152
|
-
if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
|
|
153
|
-
eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
|
|
154
|
-
else
|
|
155
|
-
eval `echo args$i`="\"$arg\""
|
|
156
|
-
fi
|
|
157
|
-
i=`expr $i + 1`
|
|
158
|
-
done
|
|
159
|
-
case $i in
|
|
160
|
-
0) set -- ;;
|
|
161
|
-
1) set -- "$args0" ;;
|
|
162
|
-
2) set -- "$args0" "$args1" ;;
|
|
163
|
-
3) set -- "$args0" "$args1" "$args2" ;;
|
|
164
|
-
4) set -- "$args0" "$args1" "$args2" "$args3" ;;
|
|
165
|
-
5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
|
|
166
|
-
6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
|
|
167
|
-
7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
|
|
168
|
-
8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
|
|
169
|
-
9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
|
|
170
|
-
esac
|
|
171
|
-
fi
|
|
172
|
-
|
|
173
|
-
# Escape application args
|
|
174
|
-
save () {
|
|
175
|
-
for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
|
|
176
|
-
echo " "
|
|
177
|
-
}
|
|
178
|
-
APP_ARGS=`save "$@"`
|
|
179
|
-
|
|
180
|
-
# Collect all arguments for the java command, following the shell quoting and substitution rules
|
|
181
|
-
eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
|
|
182
|
-
|
|
183
|
-
exec "$JAVACMD" "$@"
|
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
@rem
|
|
2
|
-
@rem Copyright 2015 the original author or authors.
|
|
3
|
-
@rem
|
|
4
|
-
@rem Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
@rem you may not use this file except in compliance with the License.
|
|
6
|
-
@rem You may obtain a copy of the License at
|
|
7
|
-
@rem
|
|
8
|
-
@rem https://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
@rem
|
|
10
|
-
@rem Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
@rem distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
@rem See the License for the specific language governing permissions and
|
|
14
|
-
@rem limitations under the License.
|
|
15
|
-
@rem
|
|
16
|
-
|
|
17
|
-
@if "%DEBUG%" == "" @echo off
|
|
18
|
-
@rem ##########################################################################
|
|
19
|
-
@rem
|
|
20
|
-
@rem Gradle startup script for Windows
|
|
21
|
-
@rem
|
|
22
|
-
@rem ##########################################################################
|
|
23
|
-
|
|
24
|
-
@rem Set local scope for the variables with windows NT shell
|
|
25
|
-
if "%OS%"=="Windows_NT" setlocal
|
|
26
|
-
|
|
27
|
-
set DIRNAME=%~dp0
|
|
28
|
-
if "%DIRNAME%" == "" set DIRNAME=.
|
|
29
|
-
set APP_BASE_NAME=%~n0
|
|
30
|
-
set APP_HOME=%DIRNAME%
|
|
31
|
-
|
|
32
|
-
@rem Resolve any "." and ".." in APP_HOME to make it shorter.
|
|
33
|
-
for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
|
|
34
|
-
|
|
35
|
-
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
|
36
|
-
set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
|
|
37
|
-
|
|
38
|
-
@rem Find java.exe
|
|
39
|
-
if defined JAVA_HOME goto findJavaFromJavaHome
|
|
40
|
-
|
|
41
|
-
set JAVA_EXE=java.exe
|
|
42
|
-
%JAVA_EXE% -version >NUL 2>&1
|
|
43
|
-
if "%ERRORLEVEL%" == "0" goto init
|
|
44
|
-
|
|
45
|
-
echo.
|
|
46
|
-
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
|
47
|
-
echo.
|
|
48
|
-
echo Please set the JAVA_HOME variable in your environment to match the
|
|
49
|
-
echo location of your Java installation.
|
|
50
|
-
|
|
51
|
-
goto fail
|
|
52
|
-
|
|
53
|
-
:findJavaFromJavaHome
|
|
54
|
-
set JAVA_HOME=%JAVA_HOME:"=%
|
|
55
|
-
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
|
|
56
|
-
|
|
57
|
-
if exist "%JAVA_EXE%" goto init
|
|
58
|
-
|
|
59
|
-
echo.
|
|
60
|
-
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
|
|
61
|
-
echo.
|
|
62
|
-
echo Please set the JAVA_HOME variable in your environment to match the
|
|
63
|
-
echo location of your Java installation.
|
|
64
|
-
|
|
65
|
-
goto fail
|
|
66
|
-
|
|
67
|
-
:init
|
|
68
|
-
@rem Get command-line arguments, handling Windows variants
|
|
69
|
-
|
|
70
|
-
if not "%OS%" == "Windows_NT" goto win9xME_args
|
|
71
|
-
|
|
72
|
-
:win9xME_args
|
|
73
|
-
@rem Slurp the command line arguments.
|
|
74
|
-
set CMD_LINE_ARGS=
|
|
75
|
-
set _SKIP=2
|
|
76
|
-
|
|
77
|
-
:win9xME_args_slurp
|
|
78
|
-
if "x%~1" == "x" goto execute
|
|
79
|
-
|
|
80
|
-
set CMD_LINE_ARGS=%*
|
|
81
|
-
|
|
82
|
-
:execute
|
|
83
|
-
@rem Setup the command line
|
|
84
|
-
|
|
85
|
-
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
|
|
86
|
-
|
|
87
|
-
@rem Execute Gradle
|
|
88
|
-
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
|
|
89
|
-
|
|
90
|
-
:end
|
|
91
|
-
@rem End local scope for the variables with windows NT shell
|
|
92
|
-
if "%ERRORLEVEL%"=="0" goto mainEnd
|
|
93
|
-
|
|
94
|
-
:fail
|
|
95
|
-
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
|
|
96
|
-
rem the _cmd.exe /c_ return code!
|
|
97
|
-
if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
|
|
98
|
-
exit /b 1
|
|
99
|
-
|
|
100
|
-
:mainEnd
|
|
101
|
-
if "%OS%"=="Windows_NT" endlocal
|
|
102
|
-
|
|
103
|
-
:omega
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
rootProject.name = '{{= it.name }}'
|
|
2
|
-
|
|
3
|
-
// Include Expo modules
|
|
4
|
-
apply from: new File(["node", "--print", "require.resolve('expo/package.json')"].execute().text.trim(), "../scripts/autolinking.gradle");
|
|
5
|
-
useExpoModules()
|
|
6
|
-
|
|
7
|
-
apply from: file("../node_modules/@react-native-community/cli-platform-android/native_modules.gradle");
|
|
8
|
-
applyNativeModulesSettingsGradle(settings)
|
|
9
|
-
|
|
10
|
-
include ':app'
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
platform :ios, '12.0'
|
|
2
|
-
|
|
3
|
-
# Import the auto-linking packages
|
|
4
|
-
require File.join(`node --print "require.resolve('react-native/package.json')"`, "../scripts/react_native_pods")
|
|
5
|
-
require File.join(`node --print "require.resolve('@react-native-community/cli-platform-ios/package.json')"`, "../native_modules")
|
|
6
|
-
require File.join(`node --print "require.resolve('expo/package.json')"`, "../scripts/autolinking")
|
|
7
|
-
|
|
8
|
-
target '{{= it.name }}' do
|
|
9
|
-
use_expo_modules!
|
|
10
|
-
config = use_native_modules!
|
|
11
|
-
|
|
12
|
-
use_react_native!(
|
|
13
|
-
:path => config[:reactNativePath],
|
|
14
|
-
# to enable hermes on iOS, change `false` to `true` and then install pods
|
|
15
|
-
:hermes_enabled => false
|
|
16
|
-
)
|
|
17
|
-
|
|
18
|
-
post_install do |installer|
|
|
19
|
-
react_native_post_install(installer)
|
|
20
|
-
|
|
21
|
-
installer.target_installation_results.pod_target_installation_results.each do |pod_name, target_installation_result|
|
|
22
|
-
target_installation_result.native_target.build_configurations.each do |config|
|
|
23
|
-
config.build_settings['EXCLUDED_ARCHS[sdk=iphonesimulator*]'] = 'arm64'
|
|
24
|
-
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '12.0'
|
|
25
|
-
end
|
|
26
|
-
end
|
|
27
|
-
|
|
28
|
-
installer.pods_project.targets.each do |target|
|
|
29
|
-
case target.name
|
|
30
|
-
when 'RCT-Folly'
|
|
31
|
-
target.build_configurations.each do |config|
|
|
32
|
-
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '9.0'
|
|
33
|
-
end
|
|
34
|
-
end
|
|
35
|
-
end
|
|
36
|
-
end
|
|
37
|
-
end
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
#import "AppDelegate.h"
|
|
2
|
-
|
|
3
|
-
#import <React/RCTBridge.h>
|
|
4
|
-
#import <React/RCTBundleURLProvider.h>
|
|
5
|
-
#import <React/RCTRootView.h>
|
|
6
|
-
#import <React/RCTLinkingManager.h>
|
|
7
|
-
|
|
8
|
-
@interface AppDelegate () <RCTBridgeDelegate>
|
|
9
|
-
|
|
10
|
-
@property (nonatomic, strong) NSDictionary *launchOptions;
|
|
11
|
-
|
|
12
|
-
@end
|
|
13
|
-
|
|
14
|
-
@implementation AppDelegate
|
|
15
|
-
|
|
16
|
-
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
|
|
17
|
-
{
|
|
18
|
-
self.launchOptions = launchOptions;
|
|
19
|
-
self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
|
|
20
|
-
|
|
21
|
-
[self initializeReactNativeApp];
|
|
22
|
-
|
|
23
|
-
[super application:application didFinishLaunchingWithOptions:launchOptions];
|
|
24
|
-
|
|
25
|
-
return YES;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
- (RCTBridge *)initializeReactNativeApp
|
|
29
|
-
{
|
|
30
|
-
RCTBridge *bridge = [[RCTBridge alloc] initWithDelegate:self launchOptions:self.launchOptions];
|
|
31
|
-
RCTRootView *rootView = [[RCTRootView alloc] initWithBridge:bridge moduleName:@"main" initialProperties:nil];
|
|
32
|
-
rootView.backgroundColor = [[UIColor alloc] initWithRed:1.0f green:1.0f blue:1.0f alpha:1];
|
|
33
|
-
|
|
34
|
-
UIViewController *rootViewController = [UIViewController new];
|
|
35
|
-
rootViewController.view = rootView;
|
|
36
|
-
self.window.rootViewController = rootViewController;
|
|
37
|
-
[self.window makeKeyAndVisible];
|
|
38
|
-
|
|
39
|
-
return bridge;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
- (NSURL *)sourceURLForBridge:(RCTBridge *)bridge {
|
|
43
|
-
#ifdef DEBUG
|
|
44
|
-
return [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index" fallbackResource:nil];
|
|
45
|
-
#else
|
|
46
|
-
return [[NSBundle mainBundle] URLForResource:@"main" withExtension:@"jsbundle"];
|
|
47
|
-
#endif
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
// Linking API
|
|
51
|
-
- (BOOL)application:(UIApplication *)application openURL:(NSURL *)url options:(NSDictionary<UIApplicationOpenURLOptionsKey,id> *)options {
|
|
52
|
-
return [RCTLinkingManager application:application openURL:url options:options];
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
// Universal Links
|
|
56
|
-
- (BOOL)application:(UIApplication *)application continueUserActivity:(nonnull NSUserActivity *)userActivity restorationHandler:(nonnull void (^)(NSArray<id<UIUserActivityRestoring>> * _Nullable))restorationHandler {
|
|
57
|
-
return [RCTLinkingManager application:application
|
|
58
|
-
continueUserActivity:userActivity
|
|
59
|
-
restorationHandler:restorationHandler];
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
@end
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"images" : [
|
|
3
|
-
{
|
|
4
|
-
"idiom" : "iphone",
|
|
5
|
-
"size" : "29x29",
|
|
6
|
-
"scale" : "2x"
|
|
7
|
-
},
|
|
8
|
-
{
|
|
9
|
-
"idiom" : "iphone",
|
|
10
|
-
"size" : "29x29",
|
|
11
|
-
"scale" : "3x"
|
|
12
|
-
},
|
|
13
|
-
{
|
|
14
|
-
"idiom" : "iphone",
|
|
15
|
-
"size" : "40x40",
|
|
16
|
-
"scale" : "2x"
|
|
17
|
-
},
|
|
18
|
-
{
|
|
19
|
-
"idiom" : "iphone",
|
|
20
|
-
"size" : "40x40",
|
|
21
|
-
"scale" : "3x"
|
|
22
|
-
},
|
|
23
|
-
{
|
|
24
|
-
"idiom" : "iphone",
|
|
25
|
-
"size" : "60x60",
|
|
26
|
-
"scale" : "2x"
|
|
27
|
-
},
|
|
28
|
-
{
|
|
29
|
-
"idiom" : "iphone",
|
|
30
|
-
"size" : "60x60",
|
|
31
|
-
"scale" : "3x"
|
|
32
|
-
}
|
|
33
|
-
],
|
|
34
|
-
"info" : {
|
|
35
|
-
"version" : 1,
|
|
36
|
-
"author" : "xcode"
|
|
37
|
-
}
|
|
38
|
-
}
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
-
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
|
3
|
-
<plist version="1.0">
|
|
4
|
-
<dict>
|
|
5
|
-
<key>CFBundleDevelopmentRegion</key>
|
|
6
|
-
<string>en</string>
|
|
7
|
-
<key>CFBundleDisplayName</key>
|
|
8
|
-
<string>{{= it.name }}</string>
|
|
9
|
-
<key>CFBundleExecutable</key>
|
|
10
|
-
<string>$(EXECUTABLE_NAME)</string>
|
|
11
|
-
<key>CFBundleIdentifier</key>
|
|
12
|
-
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
|
|
13
|
-
<key>CFBundleInfoDictionaryVersion</key>
|
|
14
|
-
<string>6.0</string>
|
|
15
|
-
<key>CFBundleName</key>
|
|
16
|
-
<string>$(PRODUCT_NAME)</string>
|
|
17
|
-
<key>CFBundlePackageType</key>
|
|
18
|
-
<string>APPL</string>
|
|
19
|
-
<key>CFBundleShortVersionString</key>
|
|
20
|
-
<string>1.0</string>
|
|
21
|
-
<key>CFBundleSignature</key>
|
|
22
|
-
<string>????</string>
|
|
23
|
-
<key>CFBundleVersion</key>
|
|
24
|
-
<string>1</string>
|
|
25
|
-
<key>LSRequiresIPhoneOS</key>
|
|
26
|
-
<true/>
|
|
27
|
-
<key>NSAppTransportSecurity</key>
|
|
28
|
-
<dict>
|
|
29
|
-
<key>NSExceptionDomains</key>
|
|
30
|
-
<dict>
|
|
31
|
-
<key>localhost</key>
|
|
32
|
-
<dict>
|
|
33
|
-
<key>NSExceptionAllowsInsecureHTTPLoads</key>
|
|
34
|
-
<true/>
|
|
35
|
-
</dict>
|
|
36
|
-
</dict>
|
|
37
|
-
</dict>
|
|
38
|
-
<key>NSLocationWhenInUseUsageDescription</key>
|
|
39
|
-
<string></string>
|
|
40
|
-
<key>UILaunchStoryboardName</key>
|
|
41
|
-
<string>LaunchScreen</string>
|
|
42
|
-
<key>UIRequiredDeviceCapabilities</key>
|
|
43
|
-
<array>
|
|
44
|
-
<string>armv7</string>
|
|
45
|
-
</array>
|
|
46
|
-
<key>UISupportedInterfaceOrientations</key>
|
|
47
|
-
<array>
|
|
48
|
-
<string>UIInterfaceOrientationPortrait</string>
|
|
49
|
-
<string>UIInterfaceOrientationLandscapeLeft</string>
|
|
50
|
-
<string>UIInterfaceOrientationLandscapeRight</string>
|
|
51
|
-
</array>
|
|
52
|
-
<key>UIViewControllerBasedStatusBarAppearance</key>
|
|
53
|
-
<false/>
|
|
54
|
-
</dict>
|
|
55
|
-
</plist>
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
-
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="15702" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="01J-lp-oVM">
|
|
3
|
-
<device id="retina4_7" orientation="portrait" appearance="light"/>
|
|
4
|
-
<dependencies>
|
|
5
|
-
<deployment identifier="iOS"/>
|
|
6
|
-
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="15704"/>
|
|
7
|
-
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
|
|
8
|
-
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
|
9
|
-
</dependencies>
|
|
10
|
-
<scenes>
|
|
11
|
-
<!--View Controller-->
|
|
12
|
-
<scene sceneID="EHf-IW-A2E">
|
|
13
|
-
<objects>
|
|
14
|
-
<viewController id="01J-lp-oVM" sceneMemberID="viewController">
|
|
15
|
-
<view key="view" contentMode="scaleToFill" id="Ze5-6b-2t3">
|
|
16
|
-
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
|
|
17
|
-
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
|
18
|
-
<subviews>
|
|
19
|
-
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="{{= it.name }}" textAlignment="center" lineBreakMode="middleTruncation" baselineAdjustment="alignBaselines" minimumFontSize="18" translatesAutoresizingMaskIntoConstraints="NO" id="GJd-Yh-RWb">
|
|
20
|
-
<rect key="frame" x="0.0" y="202" width="375" height="43"/>
|
|
21
|
-
<fontDescription key="fontDescription" type="boldSystem" pointSize="36"/>
|
|
22
|
-
<nil key="highlightedColor"/>
|
|
23
|
-
</label>
|
|
24
|
-
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Powered by React Native" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" minimumFontSize="9" translatesAutoresizingMaskIntoConstraints="NO" id="MN2-I3-ftu">
|
|
25
|
-
<rect key="frame" x="0.0" y="626" width="375" height="21"/>
|
|
26
|
-
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
|
27
|
-
<nil key="highlightedColor"/>
|
|
28
|
-
</label>
|
|
29
|
-
</subviews>
|
|
30
|
-
<color key="backgroundColor" systemColor="systemBackgroundColor" cocoaTouchSystemColor="whiteColor"/>
|
|
31
|
-
<constraints>
|
|
32
|
-
<constraint firstItem="Bcu-3y-fUS" firstAttribute="bottom" secondItem="MN2-I3-ftu" secondAttribute="bottom" constant="20" id="OZV-Vh-mqD"/>
|
|
33
|
-
<constraint firstItem="Bcu-3y-fUS" firstAttribute="centerX" secondItem="GJd-Yh-RWb" secondAttribute="centerX" id="Q3B-4B-g5h"/>
|
|
34
|
-
<constraint firstItem="MN2-I3-ftu" firstAttribute="centerX" secondItem="Bcu-3y-fUS" secondAttribute="centerX" id="akx-eg-2ui"/>
|
|
35
|
-
<constraint firstItem="MN2-I3-ftu" firstAttribute="leading" secondItem="Bcu-3y-fUS" secondAttribute="leading" id="i1E-0Y-4RG"/>
|
|
36
|
-
<constraint firstItem="GJd-Yh-RWb" firstAttribute="centerY" secondItem="Ze5-6b-2t3" secondAttribute="bottom" multiplier="1/3" constant="1" id="moa-c2-u7t"/>
|
|
37
|
-
<constraint firstItem="GJd-Yh-RWb" firstAttribute="leading" secondItem="Bcu-3y-fUS" secondAttribute="leading" symbolic="YES" id="x7j-FC-K8j"/>
|
|
38
|
-
</constraints>
|
|
39
|
-
<viewLayoutGuide key="safeArea" id="Bcu-3y-fUS"/>
|
|
40
|
-
</view>
|
|
41
|
-
</viewController>
|
|
42
|
-
<placeholder placeholderIdentifier="IBFirstResponder" id="iYj-Kq-Ea1" userLabel="First Responder" sceneMemberID="firstResponder"/>
|
|
43
|
-
</objects>
|
|
44
|
-
<point key="canvasLocation" x="52.173913043478265" y="375"/>
|
|
45
|
-
</scene>
|
|
46
|
-
</scenes>
|
|
47
|
-
</document>
|
|
File without changes
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "{{= it.name }}",
|
|
3
|
-
"version": "0.0.1",
|
|
4
|
-
"private": true,
|
|
5
|
-
"scripts": {
|
|
6
|
-
"android": "react-native run-android",
|
|
7
|
-
"ios": "react-native run-ios",
|
|
8
|
-
"start": "react-native start",
|
|
9
|
-
"test": "jest",
|
|
10
|
-
"lint": "eslint ."
|
|
11
|
-
},
|
|
12
|
-
"dependencies": {
|
|
13
|
-
"react": "{{= it.reactVersion }}",
|
|
14
|
-
"react-native": "{{= it.reactNativeVersion }}"
|
|
15
|
-
{{~ it.dependencies : dependency }}
|
|
16
|
-
, "{{= dependency.name }}": "{{= dependency.path }}"
|
|
17
|
-
{{~}}
|
|
18
|
-
},
|
|
19
|
-
"devDependencies": {
|
|
20
|
-
"@babel/core": "^7.15.0",
|
|
21
|
-
"@babel/runtime": "^7.14.8",
|
|
22
|
-
"@react-native-community/eslint-config": "^3.0.0",
|
|
23
|
-
"babel-jest": "^27.0.6",
|
|
24
|
-
"eslint": "^7.32.0",
|
|
25
|
-
"jest": "^27.0.6",
|
|
26
|
-
"react-test-renderer": "17.0.1",
|
|
27
|
-
"typescript": "~4.0.0",
|
|
28
|
-
"babel-preset-expo": "8.4.1",
|
|
29
|
-
"@types/jest": "^26.0.4"
|
|
30
|
-
{{~ it.devDependencies : dependency }}
|
|
31
|
-
, "{{= dependency.name }}": "{{= dependency.path }}"
|
|
32
|
-
{{~}}
|
|
33
|
-
},
|
|
34
|
-
"jest": {
|
|
35
|
-
"preset": "react-native"
|
|
36
|
-
}
|
|
37
|
-
}
|