Skip to content

Commit 8421454

Browse files
authored
Merge pull request #39 from functionland/deep-troubleshoot1
Corrected issue with crashes and with not being able to reload tree
2 parents 928e045 + 9a47ee4 commit 8421454

File tree

14 files changed

+2596
-2173
lines changed

14 files changed

+2596
-2173
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,3 +67,5 @@ android/keystores/debug.keystore
6767

6868
# generated by bob
6969
lib/
70+
example/yarn.lock
71+
yarn.lock

android/build.gradle

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ buildscript {
77
}
88

99
dependencies {
10-
classpath 'com.android.tools.build:gradle:4.2.2'
10+
classpath 'com.android.tools.build:gradle:7.3.0'
1111
}
1212
}
1313
}
@@ -40,7 +40,6 @@ android {
4040
sourceCompatibility JavaVersion.VERSION_1_8
4141
targetCompatibility JavaVersion.VERSION_1_8
4242
}
43-
buildToolsVersion '33.0.0'
4443
ndkVersion '25.1.8937393'
4544
}
4645

@@ -63,7 +62,8 @@ repositories {
6362
dependencies {
6463
//noinspection GradleDynamicVersion
6564
implementation "com.facebook.react:react-native:+" // From node_modules
66-
implementation 'com.github.functionland:fula-build-aar:v0.7.3' // From jitpack.io
67-
implementation 'com.github.functionland:wnfs-build-aar:v1.3.1' // From jitpack.io
65+
implementation 'com.github.functionland:fula-build-aar:v0.7.4' // From jitpack.io
66+
implementation 'com.github.functionland:wnfs-build-aar:v1.3.9' // From jitpack.io
67+
implementation 'commons-io:commons-io:20030203.000550'
6868
// implementation files('mobile.aar')
6969
}
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#Wed Nov 16 15:32:27 EST 2022
22
distributionBase=GRADLE_USER_HOME
33
distributionPath=wrapper/dists
4+
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-all.zip
45
zipStoreBase=GRADLE_USER_HOME
56
zipStorePath=wrapper/dists
67
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-all.zip

android/gradlew

Lines changed: 135 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
#!/bin/sh
2+
#!/bin/sh
23

34
#
45
# Copyright © 2015-2021 the original authors.
6+
# Copyright © 2015-2021 the original authors.
57
#
68
# Licensed under the Apache License, Version 2.0 (the "License");
79
# you may not use this file except in compliance with the License.
@@ -60,13 +62,70 @@
6062
#
6163
# You can find Gradle at https://github.com/gradle/gradle/.
6264
#
65+
#
66+
# Gradle start up script for POSIX generated by Gradle.
67+
#
68+
# Important for running:
69+
#
70+
# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is
71+
# noncompliant, but you have some other compliant shell such as ksh or
72+
# bash, then to run this script, type that shell name before the whole
73+
# command line, like:
74+
#
75+
# ksh Gradle
76+
#
77+
# Busybox and similar reduced shells will NOT work, because this script
78+
# requires all of these POSIX shell features:
79+
# * functions;
80+
# * expansions «$var», «${var}», «${var:-default}», «${var+SET}»,
81+
# «${var#prefix}», «${var%suffix}», and «$( cmd )»;
82+
# * compound commands having a testable exit status, especially «case»;
83+
# * various built-in commands including «command», «set», and «ulimit».
84+
#
85+
# Important for patching:
86+
#
87+
# (2) This script targets any POSIX shell, so it avoids extensions provided
88+
# by Bash, Ksh, etc; in particular arrays are avoided.
89+
#
90+
# The "traditional" practice of packing multiple parameters into a
91+
# space-separated string is a well documented source of bugs and security
92+
# problems, so this is (mostly) avoided, by progressively accumulating
93+
# options in "$@", and eventually passing that to Java.
94+
#
95+
# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS,
96+
# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly;
97+
# see the in-line comments for details.
98+
#
99+
# There are tweaks for specific operating systems such as AIX, CygWin,
100+
# Darwin, MinGW, and NonStop.
101+
#
102+
# (3) This script is generated from the Groovy template
103+
# https://github.com/gradle/gradle/blob/master/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
104+
# within the Gradle project.
105+
#
106+
# You can find Gradle at https://github.com/gradle/gradle/.
107+
#
63108
##############################################################################
64109

65110
# Attempt to set APP_HOME
66111

112+
67113
# Resolve links: $0 may be a link
68114
app_path=$0
69115

116+
# Need this for daisy-chained symlinks.
117+
while
118+
APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path
119+
[ -h "$app_path" ]
120+
do
121+
ls=$( ls -ld "$app_path" )
122+
link=${ls#*' -> '}
123+
case $link in #(
124+
/*) app_path=$link ;; #(
125+
*) app_path=$APP_HOME$link ;;
126+
esac
127+
app_path=$0
128+
70129
# Need this for daisy-chained symlinks.
71130
while
72131
APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path
@@ -82,31 +141,42 @@ done
82141

83142
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
84143

144+
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
145+
85146
APP_NAME="Gradle"
86147
APP_BASE_NAME=${0##*/}
148+
APP_BASE_NAME=${0##*/}
87149

88150
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
89151
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
90152

91153
# Use the maximum available, or set MAX_FD != -1 to use that value.
92154
MAX_FD=maximum
155+
MAX_FD=maximum
93156

94157
warn () {
95158
echo "$*"
96159
} >&2
160+
} >&2
97161

98162
die () {
99163
echo
100164
echo "$*"
101165
echo
102166
exit 1
103167
} >&2
168+
} >&2
104169

105170
# OS specific support (must be 'true' or 'false').
106171
cygwin=false
107172
msys=false
108173
darwin=false
109174
nonstop=false
175+
case "$( uname )" in #(
176+
CYGWIN* ) cygwin=true ;; #(
177+
Darwin* ) darwin=true ;; #(
178+
MSYS* | MINGW* ) msys=true ;; #(
179+
NONSTOP* ) nonstop=true ;;
110180
case "$( uname )" in #(
111181
CYGWIN* ) cygwin=true ;; #(
112182
Darwin* ) darwin=true ;; #(
@@ -117,13 +187,16 @@ esac
117187
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
118188

119189

190+
120191
# Determine the Java command to use to start the JVM.
121192
if [ -n "$JAVA_HOME" ] ; then
122193
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
123194
# IBM's JDK on AIX uses strange locations for the executables
124195
JAVACMD=$JAVA_HOME/jre/sh/java
196+
JAVACMD=$JAVA_HOME/jre/sh/java
125197
else
126198
JAVACMD=$JAVA_HOME/bin/java
199+
JAVACMD=$JAVA_HOME/bin/java
127200
fi
128201
if [ ! -x "$JAVACMD" ] ; then
129202
die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
@@ -132,6 +205,7 @@ Please set the JAVA_HOME variable in your environment to match the
132205
location of your Java installation."
133206
fi
134207
else
208+
JAVACMD=java
135209
JAVACMD=java
136210
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
137211
@@ -140,6 +214,18 @@ location of your Java installation."
140214
fi
141215

142216
# Increase the maximum file descriptors if we can.
217+
if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
218+
case $MAX_FD in #(
219+
max*)
220+
MAX_FD=$( ulimit -H -n ) ||
221+
warn "Could not query maximum file descriptor limit"
222+
esac
223+
case $MAX_FD in #(
224+
'' | soft) :;; #(
225+
*)
226+
ulimit -n "$MAX_FD" ||
227+
warn "Could not set maximum file descriptor limit to $MAX_FD"
228+
esac
143229
if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
144230
case $MAX_FD in #(
145231
max*)
@@ -154,6 +240,13 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
154240
esac
155241
fi
156242

243+
# Collect all arguments for the java command, stacking in reverse order:
244+
# * args from the command line
245+
# * the main class name
246+
# * -classpath
247+
# * -D...appname settings
248+
# * --module-path (only if needed)
249+
# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables.
157250
# Collect all arguments for the java command, stacking in reverse order:
158251
# * args from the command line
159252
# * the main class name
@@ -168,8 +261,23 @@ if "$cygwin" || "$msys" ; then
168261
CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" )
169262

170263
JAVACMD=$( cygpath --unix "$JAVACMD" )
264+
if "$cygwin" || "$msys" ; then
265+
APP_HOME=$( cygpath --path --mixed "$APP_HOME" )
266+
CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" )
267+
268+
JAVACMD=$( cygpath --unix "$JAVACMD" )
171269

172270
# Now convert the arguments - kludge to limit ourselves to /bin/sh
271+
for arg do
272+
if
273+
case $arg in #(
274+
-*) false ;; # don't mess with options #(
275+
/?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath
276+
[ -e "$t" ] ;; #(
277+
*) false ;;
278+
esac
279+
then
280+
arg=$( cygpath --path --ignore --mixed "$arg" )
173281
for arg do
174282
if
175283
case $arg in #(
@@ -190,6 +298,15 @@ if "$cygwin" || "$msys" ; then
190298
# iterations, nor the values presented in `arg`.
191299
shift # remove old arg
192300
set -- "$@" "$arg" # push replacement arg
301+
# Roll the args list around exactly as many times as the number of
302+
# args, so each arg winds up back in the position where it started, but
303+
# possibly modified.
304+
#
305+
# NB: a `for` loop captures its iteration list before it begins, so
306+
# changing the positional parameters here affects neither the number of
307+
# iterations, nor the values presented in `arg`.
308+
shift # remove old arg
309+
set -- "$@" "$arg" # push replacement arg
193310
done
194311
fi
195312

@@ -211,6 +328,18 @@ then
211328
die "xargs is not available"
212329
fi
213330

331+
# Collect all arguments for the java command;
332+
# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of
333+
# shell script including quotes and variable substitutions, so put them in
334+
# double quotes to make sure that they get re-expanded; and
335+
# * put everything else in single quotes, so that it's not re-expanded.
336+
337+
set -- \
338+
"-Dorg.gradle.appname=$APP_BASE_NAME" \
339+
-classpath "$CLASSPATH" \
340+
org.gradle.wrapper.GradleWrapperMain \
341+
"$@"
342+
214343
# Use "xargs" to parse quoted args.
215344
#
216345
# With -n1 it outputs one arg per line, with the quotes and backslashes removed.
@@ -230,6 +359,12 @@ fi
230359
# an unmatched quote.
231360
#
232361

362+
eval "set -- $(
363+
printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" |
364+
xargs -n1 |
365+
sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' |
366+
tr '\n' ' '
367+
)" '"$@"'
233368
eval "set -- $(
234369
printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" |
235370
xargs -n1 |

0 commit comments

Comments
 (0)