diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index f2ac9c5..f9aaacc 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -71,7 +71,7 @@ jobs: uses: actions/checkout@v4 - name: React native codegen - working-directory: lib/ls-sdk-react-native + working-directory: packages/react-native run: | yarn global add tslint typescript brew update diff --git a/lib/ls-sdk-react-native/makefile b/lib/ls-sdk-react-native/makefile deleted file mode 100644 index cc61e74..0000000 --- a/lib/ls-sdk-react-native/makefile +++ /dev/null @@ -1,41 +0,0 @@ -.PHONY: init -init: - make -C ../bindings init - -.PHONY: clean -clean: - make -C ../bindings clean - -all: android ios react-native - -react-native: - make -C ../bindings react-native - cp -r ../bindings/bindings-react-native/android/* android/ - cp -r ../bindings/bindings-react-native/ios/* ios/ - cp -r ../bindings/bindings-react-native/ts/src/* src/ - -android-make: - make -C ../bindings android - -android-copy: - mkdir -p android/src/main/jniLibs/x86 - mkdir -p android/src/main/jniLibs/x86_64 - mkdir -p android/src/main/jniLibs/arm64-v8a - mkdir -p android/src/main/jniLibs/armeabi-v7a - cp ../bindings/ffi/kotlin/breez_liquid_sdk/breez_liquid_sdk.kt android/src/main/java/com/breezliquidsdk/breez_liquid_sdk.kt - cp ../bindings/ffi/kotlin/jniLibs/x86/libbreez_liquid_sdk_bindings.so android/src/main/jniLibs/x86/libbreez_liquid_sdk_bindings.so - cp ../bindings/ffi/kotlin/jniLibs/x86_64/libbreez_liquid_sdk_bindings.so android/src/main/jniLibs/x86_64/libbreez_liquid_sdk_bindings.so - cp ../bindings/ffi/kotlin/jniLibs/arm64-v8a/libbreez_liquid_sdk_bindings.so android/src/main/jniLibs/arm64-v8a/libbreez_liquid_sdk_bindings.so - cp ../bindings/ffi/kotlin/jniLibs/armeabi-v7a/libbreez_liquid_sdk_bindings.so android/src/main/jniLibs/armeabi-v7a/libbreez_liquid_sdk_bindings.so - -android: android-make android-copy - -ios-make: - make -C ../bindings bindings-swift - -ios-copy: - rm -rf ios/bindings-swift - cp -r ../bindings/bindings-swift ios/bindings-swift - rm -f ios/bindings-swift/Package.swift - -ios: ios-make ios-copy diff --git a/lib/ls-sdk-react-native/.gitignore b/packages/react-native/.gitignore similarity index 100% rename from lib/ls-sdk-react-native/.gitignore rename to packages/react-native/.gitignore diff --git a/lib/ls-sdk-react-native/BreezLiquidSDK.podspec.dev b/packages/react-native/BreezLiquidSDK.podspec.dev similarity index 100% rename from lib/ls-sdk-react-native/BreezLiquidSDK.podspec.dev rename to packages/react-native/BreezLiquidSDK.podspec.dev diff --git a/lib/ls-sdk-react-native/DEVELOPING.md b/packages/react-native/DEVELOPING.md similarity index 90% rename from lib/ls-sdk-react-native/DEVELOPING.md rename to packages/react-native/DEVELOPING.md index 0254eb1..7e80677 100644 --- a/lib/ls-sdk-react-native/DEVELOPING.md +++ b/packages/react-native/DEVELOPING.md @@ -8,7 +8,7 @@ The Breez Liquid SDK React Native plugin consumes the underlying Breez Liquid SD When developing, it can be useful to work with a locally built version of the Breez Liquid SDK instead of relying on what is published already on CocoaPods / Jitpack. To do this, you first need to build the Breez Liquid SDK bindings locally and then point the plugin to make use of the locally built Breez Liquid SDK bindings. -All the following commands can be run in the `lib/ls-sdk-react-native` directory. +All the following commands can be run in the `packages/react-native` directory. ## Prerequisites @@ -70,11 +70,11 @@ make ios react-native To use the locally built bindings instead of integrating them remotely, make the following changes: - For iOS: - - Rename the podspec files in `lib/ls-sdk-react-native/`: + - Rename the podspec files in `packages/react-native/`: - Rename `breez_liquid_sdk.podspec` to `breez_liquid_sdk.podspec.prod` - Rename `BreezLiquidSDK.podspec.dev` to `BreezLiquidSDK.podspec` - For Android: - - Comment out the following line from the dependencies section in `lib/ls-sdk-react-native/android/build.gradle`: + - Comment out the following line from the dependencies section in `packages/react-native/android/build.gradle`: - `implementation("com.github.breez:breez-liquid-sdk:${getVersionFromNpmPackage()}") { exclude group:"net.java.dev.jna" }` Reinstall the dependencies in the example project and run it. @@ -83,7 +83,7 @@ It will now use the locally built bindings. ## Testing with the example app To test locally built bindings in the example app, the npm dependencies need to be updated to use the local package. -In `lib/ls-sdk-react-native/example/package.json` replace the current version with `file:../`: +In `packages/react-native/example/package.json` replace the current version with `file:../`: ```json "@breeztech/react-native-breez-liquid-sdk": "file:../", ``` @@ -93,7 +93,7 @@ Run the npm/yarn install to download dependences for both the react-native-breez yarn bootstrap ``` -Finally in the `lib/ls-sdk-react-native/example/` directory start either the iOS or Android app: +Finally in the `packages/react-native/example/` directory start either the iOS or Android app: ```bash yarn android ``` diff --git a/lib/ls-sdk-react-native/LICENSE b/packages/react-native/LICENSE similarity index 100% rename from lib/ls-sdk-react-native/LICENSE rename to packages/react-native/LICENSE diff --git a/lib/ls-sdk-react-native/PUBLISHING.md b/packages/react-native/PUBLISHING.md similarity index 100% rename from lib/ls-sdk-react-native/PUBLISHING.md rename to packages/react-native/PUBLISHING.md diff --git a/lib/ls-sdk-react-native/android/build.gradle b/packages/react-native/android/build.gradle similarity index 100% rename from lib/ls-sdk-react-native/android/build.gradle rename to packages/react-native/android/build.gradle diff --git a/lib/ls-sdk-react-native/android/gradle/wrapper/gradle-wrapper.jar b/packages/react-native/android/gradle/wrapper/gradle-wrapper.jar similarity index 100% rename from lib/ls-sdk-react-native/android/gradle/wrapper/gradle-wrapper.jar rename to packages/react-native/android/gradle/wrapper/gradle-wrapper.jar diff --git a/lib/ls-sdk-react-native/android/gradle/wrapper/gradle-wrapper.properties b/packages/react-native/android/gradle/wrapper/gradle-wrapper.properties similarity index 100% rename from lib/ls-sdk-react-native/android/gradle/wrapper/gradle-wrapper.properties rename to packages/react-native/android/gradle/wrapper/gradle-wrapper.properties diff --git a/lib/ls-sdk-react-native/android/gradlew b/packages/react-native/android/gradlew similarity index 100% rename from lib/ls-sdk-react-native/android/gradlew rename to packages/react-native/android/gradlew diff --git a/lib/ls-sdk-react-native/android/gradlew.bat b/packages/react-native/android/gradlew.bat similarity index 96% rename from lib/ls-sdk-react-native/android/gradlew.bat rename to packages/react-native/android/gradlew.bat index ac1b06f..107acd3 100644 --- a/lib/ls-sdk-react-native/android/gradlew.bat +++ b/packages/react-native/android/gradlew.bat @@ -1,89 +1,89 @@ -@rem -@rem Copyright 2015 the original author or authors. -@rem -@rem Licensed under the Apache License, Version 2.0 (the "License"); -@rem you may not use this file except in compliance with the License. -@rem You may obtain a copy of the License at -@rem -@rem https://www.apache.org/licenses/LICENSE-2.0 -@rem -@rem Unless required by applicable law or agreed to in writing, software -@rem distributed under the License is distributed on an "AS IS" BASIS, -@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -@rem See the License for the specific language governing permissions and -@rem limitations under the License. -@rem - -@if "%DEBUG%" == "" @echo off -@rem ########################################################################## -@rem -@rem Gradle startup script for Windows -@rem -@rem ########################################################################## - -@rem Set local scope for the variables with windows NT shell -if "%OS%"=="Windows_NT" setlocal - -set DIRNAME=%~dp0 -if "%DIRNAME%" == "" set DIRNAME=. -set APP_BASE_NAME=%~n0 -set APP_HOME=%DIRNAME% - -@rem Resolve any "." and ".." in APP_HOME to make it shorter. -for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi - -@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" - -@rem Find java.exe -if defined JAVA_HOME goto findJavaFromJavaHome - -set JAVA_EXE=java.exe -%JAVA_EXE% -version >NUL 2>&1 -if "%ERRORLEVEL%" == "0" goto execute - -echo. -echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. - -goto fail - -:findJavaFromJavaHome -set JAVA_HOME=%JAVA_HOME:"=% -set JAVA_EXE=%JAVA_HOME%/bin/java.exe - -if exist "%JAVA_EXE%" goto execute - -echo. -echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. - -goto fail - -:execute -@rem Setup the command line - -set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar - - -@rem Execute Gradle -"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* - -:end -@rem End local scope for the variables with windows NT shell -if "%ERRORLEVEL%"=="0" goto mainEnd - -:fail -rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of -rem the _cmd.exe /c_ return code! -if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 -exit /b 1 - -:mainEnd -if "%OS%"=="Windows_NT" endlocal - -:omega +@rem +@rem Copyright 2015 the original author or authors. +@rem +@rem Licensed under the Apache License, Version 2.0 (the "License"); +@rem you may not use this file except in compliance with the License. +@rem You may obtain a copy of the License at +@rem +@rem https://www.apache.org/licenses/LICENSE-2.0 +@rem +@rem Unless required by applicable law or agreed to in writing, software +@rem distributed under the License is distributed on an "AS IS" BASIS, +@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@rem See the License for the specific language governing permissions and +@rem limitations under the License. +@rem + +@if "%DEBUG%" == "" @echo off +@rem ########################################################################## +@rem +@rem Gradle startup script for Windows +@rem +@rem ########################################################################## + +@rem Set local scope for the variables with windows NT shell +if "%OS%"=="Windows_NT" setlocal + +set DIRNAME=%~dp0 +if "%DIRNAME%" == "" set DIRNAME=. +set APP_BASE_NAME=%~n0 +set APP_HOME=%DIRNAME% + +@rem Resolve any "." and ".." in APP_HOME to make it shorter. +for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi + +@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" + +@rem Find java.exe +if defined JAVA_HOME goto findJavaFromJavaHome + +set JAVA_EXE=java.exe +%JAVA_EXE% -version >NUL 2>&1 +if "%ERRORLEVEL%" == "0" goto execute + +echo. +echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. +echo. +echo Please set the JAVA_HOME variable in your environment to match the +echo location of your Java installation. + +goto fail + +:findJavaFromJavaHome +set JAVA_HOME=%JAVA_HOME:"=% +set JAVA_EXE=%JAVA_HOME%/bin/java.exe + +if exist "%JAVA_EXE%" goto execute + +echo. +echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% +echo. +echo Please set the JAVA_HOME variable in your environment to match the +echo location of your Java installation. + +goto fail + +:execute +@rem Setup the command line + +set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar + + +@rem Execute Gradle +"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* + +:end +@rem End local scope for the variables with windows NT shell +if "%ERRORLEVEL%"=="0" goto mainEnd + +:fail +rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of +rem the _cmd.exe /c_ return code! +if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 +exit /b 1 + +:mainEnd +if "%OS%"=="Windows_NT" endlocal + +:omega diff --git a/lib/ls-sdk-react-native/android/src/main/AndroidManifest.xml b/packages/react-native/android/src/main/AndroidManifest.xml similarity index 100% rename from lib/ls-sdk-react-native/android/src/main/AndroidManifest.xml rename to packages/react-native/android/src/main/AndroidManifest.xml diff --git a/lib/ls-sdk-react-native/android/src/main/java/com/breezliquidsdk/BreezLiquidSDKMapper.kt b/packages/react-native/android/src/main/java/com/breezliquidsdk/BreezLiquidSDKMapper.kt similarity index 100% rename from lib/ls-sdk-react-native/android/src/main/java/com/breezliquidsdk/BreezLiquidSDKMapper.kt rename to packages/react-native/android/src/main/java/com/breezliquidsdk/BreezLiquidSDKMapper.kt diff --git a/lib/ls-sdk-react-native/android/src/main/java/com/breezliquidsdk/BreezLiquidSDKModule.kt b/packages/react-native/android/src/main/java/com/breezliquidsdk/BreezLiquidSDKModule.kt similarity index 100% rename from lib/ls-sdk-react-native/android/src/main/java/com/breezliquidsdk/BreezLiquidSDKModule.kt rename to packages/react-native/android/src/main/java/com/breezliquidsdk/BreezLiquidSDKModule.kt diff --git a/lib/ls-sdk-react-native/android/src/main/java/com/breezliquidsdk/BreezLiquidSDKPackage.kt b/packages/react-native/android/src/main/java/com/breezliquidsdk/BreezLiquidSDKPackage.kt similarity index 100% rename from lib/ls-sdk-react-native/android/src/main/java/com/breezliquidsdk/BreezLiquidSDKPackage.kt rename to packages/react-native/android/src/main/java/com/breezliquidsdk/BreezLiquidSDKPackage.kt diff --git a/lib/ls-sdk-react-native/breez_liquid_sdk.podspec b/packages/react-native/breez_liquid_sdk.podspec similarity index 100% rename from lib/ls-sdk-react-native/breez_liquid_sdk.podspec rename to packages/react-native/breez_liquid_sdk.podspec diff --git a/lib/ls-sdk-react-native/example/.eslintrc.js b/packages/react-native/example/.eslintrc.js similarity index 100% rename from lib/ls-sdk-react-native/example/.eslintrc.js rename to packages/react-native/example/.eslintrc.js diff --git a/lib/ls-sdk-react-native/example/.gitignore b/packages/react-native/example/.gitignore similarity index 100% rename from lib/ls-sdk-react-native/example/.gitignore rename to packages/react-native/example/.gitignore diff --git a/lib/ls-sdk-react-native/example/.prettierrc b/packages/react-native/example/.prettierrc similarity index 100% rename from lib/ls-sdk-react-native/example/.prettierrc rename to packages/react-native/example/.prettierrc diff --git a/lib/ls-sdk-react-native/example/.prettierrc.js b/packages/react-native/example/.prettierrc.js similarity index 100% rename from lib/ls-sdk-react-native/example/.prettierrc.js rename to packages/react-native/example/.prettierrc.js diff --git a/lib/ls-sdk-react-native/example/.ruby-version b/packages/react-native/example/.ruby-version similarity index 100% rename from lib/ls-sdk-react-native/example/.ruby-version rename to packages/react-native/example/.ruby-version diff --git a/lib/ls-sdk-react-native/example/.watchmanconfig b/packages/react-native/example/.watchmanconfig similarity index 100% rename from lib/ls-sdk-react-native/example/.watchmanconfig rename to packages/react-native/example/.watchmanconfig diff --git a/lib/ls-sdk-react-native/example/App.js b/packages/react-native/example/App.js similarity index 100% rename from lib/ls-sdk-react-native/example/App.js rename to packages/react-native/example/App.js diff --git a/lib/ls-sdk-react-native/example/Gemfile b/packages/react-native/example/Gemfile similarity index 100% rename from lib/ls-sdk-react-native/example/Gemfile rename to packages/react-native/example/Gemfile diff --git a/lib/ls-sdk-react-native/example/Gemfile.lock b/packages/react-native/example/Gemfile.lock similarity index 100% rename from lib/ls-sdk-react-native/example/Gemfile.lock rename to packages/react-native/example/Gemfile.lock diff --git a/lib/ls-sdk-react-native/example/README.md b/packages/react-native/example/README.md similarity index 100% rename from lib/ls-sdk-react-native/example/README.md rename to packages/react-native/example/README.md diff --git a/lib/ls-sdk-react-native/example/android/app/_BUCK b/packages/react-native/example/android/app/_BUCK similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/_BUCK rename to packages/react-native/example/android/app/_BUCK diff --git a/lib/ls-sdk-react-native/example/android/app/build.gradle b/packages/react-native/example/android/app/build.gradle similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/build.gradle rename to packages/react-native/example/android/app/build.gradle diff --git a/lib/ls-sdk-react-native/example/android/app/build_defs.bzl b/packages/react-native/example/android/app/build_defs.bzl similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/build_defs.bzl rename to packages/react-native/example/android/app/build_defs.bzl diff --git a/lib/ls-sdk-react-native/example/android/app/debug.keystore b/packages/react-native/example/android/app/debug.keystore similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/debug.keystore rename to packages/react-native/example/android/app/debug.keystore diff --git a/lib/ls-sdk-react-native/example/android/app/proguard-rules.pro b/packages/react-native/example/android/app/proguard-rules.pro similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/proguard-rules.pro rename to packages/react-native/example/android/app/proguard-rules.pro diff --git a/lib/ls-sdk-react-native/example/android/app/src/debug/AndroidManifest.xml b/packages/react-native/example/android/app/src/debug/AndroidManifest.xml similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/debug/AndroidManifest.xml rename to packages/react-native/example/android/app/src/debug/AndroidManifest.xml diff --git a/lib/ls-sdk-react-native/example/android/app/src/debug/java/com/example/breezliquidsdk/ReactNativeFlipper.java b/packages/react-native/example/android/app/src/debug/java/com/example/breezliquidsdk/ReactNativeFlipper.java similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/debug/java/com/example/breezliquidsdk/ReactNativeFlipper.java rename to packages/react-native/example/android/app/src/debug/java/com/example/breezliquidsdk/ReactNativeFlipper.java diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/AndroidManifest.xml b/packages/react-native/example/android/app/src/main/AndroidManifest.xml similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/AndroidManifest.xml rename to packages/react-native/example/android/app/src/main/AndroidManifest.xml diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/java/com/example/breezliquidsdk/MainActivity.java b/packages/react-native/example/android/app/src/main/java/com/example/breezliquidsdk/MainActivity.java similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/java/com/example/breezliquidsdk/MainActivity.java rename to packages/react-native/example/android/app/src/main/java/com/example/breezliquidsdk/MainActivity.java diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/java/com/example/breezliquidsdk/MainApplication.java b/packages/react-native/example/android/app/src/main/java/com/example/breezliquidsdk/MainApplication.java similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/java/com/example/breezliquidsdk/MainApplication.java rename to packages/react-native/example/android/app/src/main/java/com/example/breezliquidsdk/MainApplication.java diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/java/com/example/breezliquidsdk/newarchitecture/MainApplicationReactNativeHost.java b/packages/react-native/example/android/app/src/main/java/com/example/breezliquidsdk/newarchitecture/MainApplicationReactNativeHost.java similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/java/com/example/breezliquidsdk/newarchitecture/MainApplicationReactNativeHost.java rename to packages/react-native/example/android/app/src/main/java/com/example/breezliquidsdk/newarchitecture/MainApplicationReactNativeHost.java diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/java/com/example/breezliquidsdk/newarchitecture/components/MainComponentsRegistry.java b/packages/react-native/example/android/app/src/main/java/com/example/breezliquidsdk/newarchitecture/components/MainComponentsRegistry.java similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/java/com/example/breezliquidsdk/newarchitecture/components/MainComponentsRegistry.java rename to packages/react-native/example/android/app/src/main/java/com/example/breezliquidsdk/newarchitecture/components/MainComponentsRegistry.java diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/java/com/example/breezliquidsdk/newarchitecture/modules/MainApplicationTurboModuleManagerDelegate.java b/packages/react-native/example/android/app/src/main/java/com/example/breezliquidsdk/newarchitecture/modules/MainApplicationTurboModuleManagerDelegate.java similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/java/com/example/breezliquidsdk/newarchitecture/modules/MainApplicationTurboModuleManagerDelegate.java rename to packages/react-native/example/android/app/src/main/java/com/example/breezliquidsdk/newarchitecture/modules/MainApplicationTurboModuleManagerDelegate.java diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/jni/CMakeLists.txt b/packages/react-native/example/android/app/src/main/jni/CMakeLists.txt similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/jni/CMakeLists.txt rename to packages/react-native/example/android/app/src/main/jni/CMakeLists.txt diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/jni/MainApplicationModuleProvider.cpp b/packages/react-native/example/android/app/src/main/jni/MainApplicationModuleProvider.cpp similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/jni/MainApplicationModuleProvider.cpp rename to packages/react-native/example/android/app/src/main/jni/MainApplicationModuleProvider.cpp diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/jni/MainApplicationModuleProvider.h b/packages/react-native/example/android/app/src/main/jni/MainApplicationModuleProvider.h similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/jni/MainApplicationModuleProvider.h rename to packages/react-native/example/android/app/src/main/jni/MainApplicationModuleProvider.h diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/jni/MainApplicationTurboModuleManagerDelegate.cpp b/packages/react-native/example/android/app/src/main/jni/MainApplicationTurboModuleManagerDelegate.cpp similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/jni/MainApplicationTurboModuleManagerDelegate.cpp rename to packages/react-native/example/android/app/src/main/jni/MainApplicationTurboModuleManagerDelegate.cpp diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/jni/MainApplicationTurboModuleManagerDelegate.h b/packages/react-native/example/android/app/src/main/jni/MainApplicationTurboModuleManagerDelegate.h similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/jni/MainApplicationTurboModuleManagerDelegate.h rename to packages/react-native/example/android/app/src/main/jni/MainApplicationTurboModuleManagerDelegate.h diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/jni/MainComponentsRegistry.cpp b/packages/react-native/example/android/app/src/main/jni/MainComponentsRegistry.cpp similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/jni/MainComponentsRegistry.cpp rename to packages/react-native/example/android/app/src/main/jni/MainComponentsRegistry.cpp diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/jni/MainComponentsRegistry.h b/packages/react-native/example/android/app/src/main/jni/MainComponentsRegistry.h similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/jni/MainComponentsRegistry.h rename to packages/react-native/example/android/app/src/main/jni/MainComponentsRegistry.h diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/jni/OnLoad.cpp b/packages/react-native/example/android/app/src/main/jni/OnLoad.cpp similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/jni/OnLoad.cpp rename to packages/react-native/example/android/app/src/main/jni/OnLoad.cpp diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/res/drawable/rn_edit_text_material.xml b/packages/react-native/example/android/app/src/main/res/drawable/rn_edit_text_material.xml similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/res/drawable/rn_edit_text_material.xml rename to packages/react-native/example/android/app/src/main/res/drawable/rn_edit_text_material.xml diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png b/packages/react-native/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png rename to packages/react-native/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png b/packages/react-native/example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png rename to packages/react-native/example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png b/packages/react-native/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png rename to packages/react-native/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png b/packages/react-native/example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png rename to packages/react-native/example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/packages/react-native/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png rename to packages/react-native/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png b/packages/react-native/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png rename to packages/react-native/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/packages/react-native/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png rename to packages/react-native/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png b/packages/react-native/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png rename to packages/react-native/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/packages/react-native/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png rename to packages/react-native/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png b/packages/react-native/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png rename to packages/react-native/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/res/values/strings.xml b/packages/react-native/example/android/app/src/main/res/values/strings.xml similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/res/values/strings.xml rename to packages/react-native/example/android/app/src/main/res/values/strings.xml diff --git a/lib/ls-sdk-react-native/example/android/app/src/main/res/values/styles.xml b/packages/react-native/example/android/app/src/main/res/values/styles.xml similarity index 100% rename from lib/ls-sdk-react-native/example/android/app/src/main/res/values/styles.xml rename to packages/react-native/example/android/app/src/main/res/values/styles.xml diff --git a/lib/ls-sdk-react-native/example/android/build.gradle b/packages/react-native/example/android/build.gradle similarity index 100% rename from lib/ls-sdk-react-native/example/android/build.gradle rename to packages/react-native/example/android/build.gradle diff --git a/lib/ls-sdk-react-native/example/android/gradle.properties b/packages/react-native/example/android/gradle.properties similarity index 100% rename from lib/ls-sdk-react-native/example/android/gradle.properties rename to packages/react-native/example/android/gradle.properties diff --git a/lib/ls-sdk-react-native/example/android/gradle/wrapper/gradle-wrapper.jar b/packages/react-native/example/android/gradle/wrapper/gradle-wrapper.jar similarity index 100% rename from lib/ls-sdk-react-native/example/android/gradle/wrapper/gradle-wrapper.jar rename to packages/react-native/example/android/gradle/wrapper/gradle-wrapper.jar diff --git a/lib/ls-sdk-react-native/example/android/gradle/wrapper/gradle-wrapper.properties b/packages/react-native/example/android/gradle/wrapper/gradle-wrapper.properties similarity index 100% rename from lib/ls-sdk-react-native/example/android/gradle/wrapper/gradle-wrapper.properties rename to packages/react-native/example/android/gradle/wrapper/gradle-wrapper.properties diff --git a/lib/ls-sdk-react-native/example/android/gradlew b/packages/react-native/example/android/gradlew similarity index 100% rename from lib/ls-sdk-react-native/example/android/gradlew rename to packages/react-native/example/android/gradlew diff --git a/lib/ls-sdk-react-native/example/android/gradlew.bat b/packages/react-native/example/android/gradlew.bat similarity index 96% rename from lib/ls-sdk-react-native/example/android/gradlew.bat rename to packages/react-native/example/android/gradlew.bat index ac1b06f..107acd3 100644 --- a/lib/ls-sdk-react-native/example/android/gradlew.bat +++ b/packages/react-native/example/android/gradlew.bat @@ -1,89 +1,89 @@ -@rem -@rem Copyright 2015 the original author or authors. -@rem -@rem Licensed under the Apache License, Version 2.0 (the "License"); -@rem you may not use this file except in compliance with the License. -@rem You may obtain a copy of the License at -@rem -@rem https://www.apache.org/licenses/LICENSE-2.0 -@rem -@rem Unless required by applicable law or agreed to in writing, software -@rem distributed under the License is distributed on an "AS IS" BASIS, -@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -@rem See the License for the specific language governing permissions and -@rem limitations under the License. -@rem - -@if "%DEBUG%" == "" @echo off -@rem ########################################################################## -@rem -@rem Gradle startup script for Windows -@rem -@rem ########################################################################## - -@rem Set local scope for the variables with windows NT shell -if "%OS%"=="Windows_NT" setlocal - -set DIRNAME=%~dp0 -if "%DIRNAME%" == "" set DIRNAME=. -set APP_BASE_NAME=%~n0 -set APP_HOME=%DIRNAME% - -@rem Resolve any "." and ".." in APP_HOME to make it shorter. -for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi - -@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" - -@rem Find java.exe -if defined JAVA_HOME goto findJavaFromJavaHome - -set JAVA_EXE=java.exe -%JAVA_EXE% -version >NUL 2>&1 -if "%ERRORLEVEL%" == "0" goto execute - -echo. -echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. - -goto fail - -:findJavaFromJavaHome -set JAVA_HOME=%JAVA_HOME:"=% -set JAVA_EXE=%JAVA_HOME%/bin/java.exe - -if exist "%JAVA_EXE%" goto execute - -echo. -echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. - -goto fail - -:execute -@rem Setup the command line - -set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar - - -@rem Execute Gradle -"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* - -:end -@rem End local scope for the variables with windows NT shell -if "%ERRORLEVEL%"=="0" goto mainEnd - -:fail -rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of -rem the _cmd.exe /c_ return code! -if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 -exit /b 1 - -:mainEnd -if "%OS%"=="Windows_NT" endlocal - -:omega +@rem +@rem Copyright 2015 the original author or authors. +@rem +@rem Licensed under the Apache License, Version 2.0 (the "License"); +@rem you may not use this file except in compliance with the License. +@rem You may obtain a copy of the License at +@rem +@rem https://www.apache.org/licenses/LICENSE-2.0 +@rem +@rem Unless required by applicable law or agreed to in writing, software +@rem distributed under the License is distributed on an "AS IS" BASIS, +@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@rem See the License for the specific language governing permissions and +@rem limitations under the License. +@rem + +@if "%DEBUG%" == "" @echo off +@rem ########################################################################## +@rem +@rem Gradle startup script for Windows +@rem +@rem ########################################################################## + +@rem Set local scope for the variables with windows NT shell +if "%OS%"=="Windows_NT" setlocal + +set DIRNAME=%~dp0 +if "%DIRNAME%" == "" set DIRNAME=. +set APP_BASE_NAME=%~n0 +set APP_HOME=%DIRNAME% + +@rem Resolve any "." and ".." in APP_HOME to make it shorter. +for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi + +@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" + +@rem Find java.exe +if defined JAVA_HOME goto findJavaFromJavaHome + +set JAVA_EXE=java.exe +%JAVA_EXE% -version >NUL 2>&1 +if "%ERRORLEVEL%" == "0" goto execute + +echo. +echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. +echo. +echo Please set the JAVA_HOME variable in your environment to match the +echo location of your Java installation. + +goto fail + +:findJavaFromJavaHome +set JAVA_HOME=%JAVA_HOME:"=% +set JAVA_EXE=%JAVA_HOME%/bin/java.exe + +if exist "%JAVA_EXE%" goto execute + +echo. +echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% +echo. +echo Please set the JAVA_HOME variable in your environment to match the +echo location of your Java installation. + +goto fail + +:execute +@rem Setup the command line + +set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar + + +@rem Execute Gradle +"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* + +:end +@rem End local scope for the variables with windows NT shell +if "%ERRORLEVEL%"=="0" goto mainEnd + +:fail +rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of +rem the _cmd.exe /c_ return code! +if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 +exit /b 1 + +:mainEnd +if "%OS%"=="Windows_NT" endlocal + +:omega diff --git a/lib/ls-sdk-react-native/example/android/settings.gradle b/packages/react-native/example/android/settings.gradle similarity index 100% rename from lib/ls-sdk-react-native/example/android/settings.gradle rename to packages/react-native/example/android/settings.gradle diff --git a/lib/ls-sdk-react-native/example/app.json b/packages/react-native/example/app.json similarity index 100% rename from lib/ls-sdk-react-native/example/app.json rename to packages/react-native/example/app.json diff --git a/lib/ls-sdk-react-native/example/babel.config.js b/packages/react-native/example/babel.config.js similarity index 100% rename from lib/ls-sdk-react-native/example/babel.config.js rename to packages/react-native/example/babel.config.js diff --git a/lib/ls-sdk-react-native/example/index.js b/packages/react-native/example/index.js similarity index 100% rename from lib/ls-sdk-react-native/example/index.js rename to packages/react-native/example/index.js diff --git a/lib/ls-sdk-react-native/example/ios/.xcode.env b/packages/react-native/example/ios/.xcode.env similarity index 100% rename from lib/ls-sdk-react-native/example/ios/.xcode.env rename to packages/react-native/example/ios/.xcode.env diff --git a/lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample.xcodeproj/project.pbxproj b/packages/react-native/example/ios/BreezLiquidSDKExample.xcodeproj/project.pbxproj similarity index 100% rename from lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample.xcodeproj/project.pbxproj rename to packages/react-native/example/ios/BreezLiquidSDKExample.xcodeproj/project.pbxproj diff --git a/lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample.xcodeproj/xcshareddata/xcschemes/BreezLiquidSDKExample.xcscheme b/packages/react-native/example/ios/BreezLiquidSDKExample.xcodeproj/xcshareddata/xcschemes/BreezLiquidSDKExample.xcscheme similarity index 100% rename from lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample.xcodeproj/xcshareddata/xcschemes/BreezLiquidSDKExample.xcscheme rename to packages/react-native/example/ios/BreezLiquidSDKExample.xcodeproj/xcshareddata/xcschemes/BreezLiquidSDKExample.xcscheme diff --git a/lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample.xcworkspace/contents.xcworkspacedata b/packages/react-native/example/ios/BreezLiquidSDKExample.xcworkspace/contents.xcworkspacedata similarity index 100% rename from lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample.xcworkspace/contents.xcworkspacedata rename to packages/react-native/example/ios/BreezLiquidSDKExample.xcworkspace/contents.xcworkspacedata diff --git a/lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/packages/react-native/example/ios/BreezLiquidSDKExample.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist similarity index 100% rename from lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist rename to packages/react-native/example/ios/BreezLiquidSDKExample.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist diff --git a/lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample/AppDelegate.h b/packages/react-native/example/ios/BreezLiquidSDKExample/AppDelegate.h similarity index 100% rename from lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample/AppDelegate.h rename to packages/react-native/example/ios/BreezLiquidSDKExample/AppDelegate.h diff --git a/lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample/AppDelegate.mm b/packages/react-native/example/ios/BreezLiquidSDKExample/AppDelegate.mm similarity index 100% rename from lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample/AppDelegate.mm rename to packages/react-native/example/ios/BreezLiquidSDKExample/AppDelegate.mm diff --git a/lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample/Images.xcassets/AppIcon.appiconset/Contents.json b/packages/react-native/example/ios/BreezLiquidSDKExample/Images.xcassets/AppIcon.appiconset/Contents.json similarity index 100% rename from lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample/Images.xcassets/AppIcon.appiconset/Contents.json rename to packages/react-native/example/ios/BreezLiquidSDKExample/Images.xcassets/AppIcon.appiconset/Contents.json diff --git a/lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample/Images.xcassets/Contents.json b/packages/react-native/example/ios/BreezLiquidSDKExample/Images.xcassets/Contents.json similarity index 100% rename from lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample/Images.xcassets/Contents.json rename to packages/react-native/example/ios/BreezLiquidSDKExample/Images.xcassets/Contents.json diff --git a/lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample/Info.plist b/packages/react-native/example/ios/BreezLiquidSDKExample/Info.plist similarity index 100% rename from lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample/Info.plist rename to packages/react-native/example/ios/BreezLiquidSDKExample/Info.plist diff --git a/lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample/LaunchScreen.storyboard b/packages/react-native/example/ios/BreezLiquidSDKExample/LaunchScreen.storyboard similarity index 100% rename from lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample/LaunchScreen.storyboard rename to packages/react-native/example/ios/BreezLiquidSDKExample/LaunchScreen.storyboard diff --git a/lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample/main.m b/packages/react-native/example/ios/BreezLiquidSDKExample/main.m similarity index 100% rename from lib/ls-sdk-react-native/example/ios/BreezLiquidSDKExample/main.m rename to packages/react-native/example/ios/BreezLiquidSDKExample/main.m diff --git a/lib/ls-sdk-react-native/example/ios/Podfile b/packages/react-native/example/ios/Podfile similarity index 100% rename from lib/ls-sdk-react-native/example/ios/Podfile rename to packages/react-native/example/ios/Podfile diff --git a/lib/ls-sdk-react-native/example/ios/Podfile.lock b/packages/react-native/example/ios/Podfile.lock similarity index 100% rename from lib/ls-sdk-react-native/example/ios/Podfile.lock rename to packages/react-native/example/ios/Podfile.lock diff --git a/lib/ls-sdk-react-native/example/metro.config.js b/packages/react-native/example/metro.config.js similarity index 100% rename from lib/ls-sdk-react-native/example/metro.config.js rename to packages/react-native/example/metro.config.js diff --git a/lib/ls-sdk-react-native/example/package.json b/packages/react-native/example/package.json similarity index 100% rename from lib/ls-sdk-react-native/example/package.json rename to packages/react-native/example/package.json diff --git a/lib/ls-sdk-react-native/example/types/react-native-secure-storage.d.ts b/packages/react-native/example/types/react-native-secure-storage.d.ts similarity index 100% rename from lib/ls-sdk-react-native/example/types/react-native-secure-storage.d.ts rename to packages/react-native/example/types/react-native-secure-storage.d.ts diff --git a/lib/ls-sdk-react-native/example/utils/security.ts b/packages/react-native/example/utils/security.ts similarity index 100% rename from lib/ls-sdk-react-native/example/utils/security.ts rename to packages/react-native/example/utils/security.ts diff --git a/lib/ls-sdk-react-native/example/utils/storage.ts b/packages/react-native/example/utils/storage.ts similarity index 100% rename from lib/ls-sdk-react-native/example/utils/storage.ts rename to packages/react-native/example/utils/storage.ts diff --git a/lib/ls-sdk-react-native/example/yarn.lock b/packages/react-native/example/yarn.lock similarity index 100% rename from lib/ls-sdk-react-native/example/yarn.lock rename to packages/react-native/example/yarn.lock diff --git a/lib/ls-sdk-react-native/ios/BreezLiquidSDK-Bridging-Header.h b/packages/react-native/ios/BreezLiquidSDK-Bridging-Header.h similarity index 100% rename from lib/ls-sdk-react-native/ios/BreezLiquidSDK-Bridging-Header.h rename to packages/react-native/ios/BreezLiquidSDK-Bridging-Header.h diff --git a/lib/ls-sdk-react-native/ios/BreezLiquidSDK.xcodeproj/project.pbxproj b/packages/react-native/ios/BreezLiquidSDK.xcodeproj/project.pbxproj similarity index 100% rename from lib/ls-sdk-react-native/ios/BreezLiquidSDK.xcodeproj/project.pbxproj rename to packages/react-native/ios/BreezLiquidSDK.xcodeproj/project.pbxproj diff --git a/lib/ls-sdk-react-native/ios/BreezLiquidSDK.xcodeproj/xcshareddata/xcschemes/BreezLiquidSDK.xcscheme b/packages/react-native/ios/BreezLiquidSDK.xcodeproj/xcshareddata/xcschemes/BreezLiquidSDK.xcscheme similarity index 100% rename from lib/ls-sdk-react-native/ios/BreezLiquidSDK.xcodeproj/xcshareddata/xcschemes/BreezLiquidSDK.xcscheme rename to packages/react-native/ios/BreezLiquidSDK.xcodeproj/xcshareddata/xcschemes/BreezLiquidSDK.xcscheme diff --git a/lib/ls-sdk-react-native/ios/BreezLiquidSDKMapper.swift b/packages/react-native/ios/BreezLiquidSDKMapper.swift similarity index 100% rename from lib/ls-sdk-react-native/ios/BreezLiquidSDKMapper.swift rename to packages/react-native/ios/BreezLiquidSDKMapper.swift diff --git a/lib/ls-sdk-react-native/ios/RNBreezLiquidSDK.m b/packages/react-native/ios/RNBreezLiquidSDK.m similarity index 100% rename from lib/ls-sdk-react-native/ios/RNBreezLiquidSDK.m rename to packages/react-native/ios/RNBreezLiquidSDK.m diff --git a/lib/ls-sdk-react-native/ios/RNBreezLiquidSDK.swift b/packages/react-native/ios/RNBreezLiquidSDK.swift similarity index 100% rename from lib/ls-sdk-react-native/ios/RNBreezLiquidSDK.swift rename to packages/react-native/ios/RNBreezLiquidSDK.swift diff --git a/packages/react-native/makefile b/packages/react-native/makefile new file mode 100644 index 0000000..b6d4c49 --- /dev/null +++ b/packages/react-native/makefile @@ -0,0 +1,41 @@ +.PHONY: init +init: + make -C ../../lib/bindings init + +.PHONY: clean +clean: + make -C ../../lib/bindings clean + +all: android ios react-native + +react-native: + make -C ../../lib/bindings react-native + cp -r ../../lib/bindings/bindings-react-native/android/* android/ + cp -r ../../lib/bindings/bindings-react-native/ios/* ios/ + cp -r ../../lib/bindings/bindings-react-native/ts/src/* src/ + +android-make: + make -C ../../lib/bindings android + +android-copy: + mkdir -p android/src/main/jniLibs/x86 + mkdir -p android/src/main/jniLibs/x86_64 + mkdir -p android/src/main/jniLibs/arm64-v8a + mkdir -p android/src/main/jniLibs/armeabi-v7a + cp ../../lib/bindings/ffi/kotlin/breez_liquid_sdk/breez_liquid_sdk.kt android/src/main/java/com/breezliquidsdk/breez_liquid_sdk.kt + cp ../../lib/bindings/ffi/kotlin/jniLibs/x86/libbreez_liquid_sdk_bindings.so android/src/main/jniLibs/x86/libbreez_liquid_sdk_bindings.so + cp ../../lib/bindings/ffi/kotlin/jniLibs/x86_64/libbreez_liquid_sdk_bindings.so android/src/main/jniLibs/x86_64/libbreez_liquid_sdk_bindings.so + cp ../../lib/bindings/ffi/kotlin/jniLibs/arm64-v8a/libbreez_liquid_sdk_bindings.so android/src/main/jniLibs/arm64-v8a/libbreez_liquid_sdk_bindings.so + cp ../../lib/bindings/ffi/kotlin/jniLibs/armeabi-v7a/libbreez_liquid_sdk_bindings.so android/src/main/jniLibs/armeabi-v7a/libbreez_liquid_sdk_bindings.so + +android: android-make android-copy + +ios-make: + make -C ../../lib/bindings bindings-swift + +ios-copy: + rm -rf ios/bindings-swift + cp -r ../../lib/bindings/bindings-swift ios/bindings-swift + rm -f ios/bindings-swift/Package.swift + +ios: ios-make ios-copy diff --git a/lib/ls-sdk-react-native/package.json b/packages/react-native/package.json similarity index 100% rename from lib/ls-sdk-react-native/package.json rename to packages/react-native/package.json diff --git a/lib/ls-sdk-react-native/src/index.ts b/packages/react-native/src/index.ts similarity index 100% rename from lib/ls-sdk-react-native/src/index.ts rename to packages/react-native/src/index.ts diff --git a/lib/ls-sdk-react-native/tsconfig.build.json b/packages/react-native/tsconfig.build.json similarity index 100% rename from lib/ls-sdk-react-native/tsconfig.build.json rename to packages/react-native/tsconfig.build.json diff --git a/lib/ls-sdk-react-native/tsconfig.json b/packages/react-native/tsconfig.json similarity index 100% rename from lib/ls-sdk-react-native/tsconfig.json rename to packages/react-native/tsconfig.json diff --git a/lib/ls-sdk-react-native/yarn.lock b/packages/react-native/yarn.lock similarity index 100% rename from lib/ls-sdk-react-native/yarn.lock rename to packages/react-native/yarn.lock